mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-20 10:34:30 +00:00
bind: Don't start a stopped daemon during changes/upgrades
Tests: - Without patch, disable bind. Incrementing the app's version number results in bind getting started. - With patch, disable bind. Incrementing the app's version number does not result in bind getting started. - Without patch, disable bind. Update forwarders. Bind is running again. - With patch, disable bind. Update forwarders. Bind is not running again. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: Veiko Aasa <veiko17@disroot.org>
This commit is contained in:
parent
fc66ed3121
commit
96b052432a
@ -45,14 +45,14 @@ def setup(old_version: int):
|
|||||||
|
|
||||||
Path(ZONES_DIR).mkdir(exist_ok=True, parents=True)
|
Path(ZONES_DIR).mkdir(exist_ok=True, parents=True)
|
||||||
|
|
||||||
action_utils.service_restart('named')
|
action_utils.service_try_restart('named')
|
||||||
|
|
||||||
|
|
||||||
@privileged
|
@privileged
|
||||||
def configure(forwarders: str):
|
def configure(forwarders: str):
|
||||||
"""Configure BIND."""
|
"""Configure BIND."""
|
||||||
_set_forwarders(forwarders)
|
_set_forwarders(forwarders)
|
||||||
action_utils.service_restart('named')
|
action_utils.service_try_restart('named')
|
||||||
|
|
||||||
|
|
||||||
def get_config():
|
def get_config():
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user