| @@ 36-44 (lines=9) @@ | ||
| 33 | :return: |
|
| 34 | """ |
|
| 35 | # Run after_script after successful connection |
|
| 36 | if 'after_script' in system.config[client]: |
|
| 37 | output.message( |
|
| 38 | output.host_to_subject(client), |
|
| 39 | 'Running after_script', |
|
| 40 | True |
|
| 41 | ) |
|
| 42 | mode.run_command( |
|
| 43 | system.config[client]['after_script'], |
|
| 44 | client |
|
| 45 | ) |
|
| 46 | ||
| 47 | ||
| @@ 17-25 (lines=9) @@ | ||
| 14 | :return: |
|
| 15 | """ |
|
| 16 | # Run before_script after successful connection |
|
| 17 | if 'before_script' in system.config[client]: |
|
| 18 | output.message( |
|
| 19 | output.host_to_subject(client), |
|
| 20 | 'Running before_script', |
|
| 21 | True |
|
| 22 | ) |
|
| 23 | mode.run_command( |
|
| 24 | system.config[client]['before_script'], |
|
| 25 | client |
|
| 26 | ) |
|
| 27 | ||
| 28 | ||