Disable automatic systemd dependencies
This commit is contained in:
parent
2669a7a185
commit
30ac033863
11
main.py
11
main.py
@ -101,11 +101,12 @@ def write_service_units(args, yaml_dict):
|
||||
unit_file = IniFile()
|
||||
unit_file["Unit"] = {}
|
||||
unit_file["Unit"]["Description"] = f"{service_name.capitalize()} container"
|
||||
if "depends_on" in service:
|
||||
enforce_list("depends_on", service)
|
||||
for dependency in service["depends_on"]:
|
||||
unit_file["Unit"].setdefault("Requires", []).append(f"{dependency}.service")
|
||||
unit_file["Unit"].setdefault("After", []).append(f"{dependency}.service")
|
||||
# currently decreases reliability instead of increasing it
|
||||
# if "depends_on" in service:
|
||||
# enforce_list("depends_on", service)
|
||||
# for dependency in service["depends_on"]:
|
||||
# unit_file["Unit"].setdefault("Requires", []).append(f"{dependency}.service")
|
||||
# unit_file["Unit"].setdefault("After", []).append(f"{dependency}.service")
|
||||
|
||||
unit_file["Container"] = {}
|
||||
if "container_name" in service:
|
||||
|
Loading…
Reference in New Issue
Block a user