diff options
author | Devaev Maxim <[email protected]> | 2021-02-16 09:07:51 +0300 |
---|---|---|
committer | Devaev Maxim <[email protected]> | 2021-02-16 09:07:51 +0300 |
commit | 3e289262f8a08042cd81eb7ebd8b75404020d945 (patch) | |
tree | bc46b8eea354d2e1e9544ac7f3595200e1c7d220 /kvmd/apps/__init__.py | |
parent | 70fb46d4287e33d34dbf72156372a5c55cb273f7 (diff) |
additional cmd options
Diffstat (limited to 'kvmd/apps/__init__.py')
-rw-r--r-- | kvmd/apps/__init__.py | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/kvmd/apps/__init__.py b/kvmd/apps/__init__.py index 80fc82ec..ed6a3101 100644 --- a/kvmd/apps/__init__.py +++ b/kvmd/apps/__init__.py @@ -516,7 +516,10 @@ def _get_config_scheme() -> Dict: }, "commands": { - "pre_start_cmd": Option(["/bin/true", "pre-start"], type=valid_command), + "pre_start_cmd": Option(["/bin/true", "pre-start"], type=valid_command), + "pre_start_cmd_remove": Option([], type=valid_options), + "pre_start_cmd_append": Option([], type=valid_options), + "post_start_cmd": Option([ "/usr/bin/systemd-run", "--unit=kvmd-otgnet-dnsmasq", @@ -532,12 +535,20 @@ def _get_config_scheme() -> Dict: "--dhcp-option=6", "--keep-in-foreground", ], type=valid_command), - "pre_stop_cmd": Option([ + "post_start_cmd_remove": Option([], type=valid_options), + "post_start_cmd_append": Option([], type=valid_options), + + "pre_stop_cmd": Option([ "/usr/bin/systemctl", "stop", "kvmd-otgnet-dnsmasq", ], type=valid_command), - "post_stop_cmd": Option(["/bin/true", "post-stop"], type=valid_command), + "pre_stop_cmd_remove": Option([], type=valid_options), + "pre_stop_cmd_append": Option([], type=valid_options), + + "post_stop_cmd": Option(["/bin/true", "post-stop"], type=valid_command), + "post_stop_cmd_remove": Option([], type=valid_options), + "post_stop_cmd_append": Option([], type=valid_options), }, }, |