From f0e81e83eec307e4cff85328d0d8ddac0c13e3ac Mon Sep 17 00:00:00 2001 From: jaydee Date: Mon, 16 Dec 2024 23:53:22 +0100 Subject: [PATCH] initial --- omv_backup.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/omv_backup.py b/omv_backup.py index ad6a883..0777c02 100644 --- a/omv_backup.py +++ b/omv_backup.py @@ -218,7 +218,9 @@ if _RESTORE: status, output = subprocess.getstatusoutput(cmnd) - if app == "heimdall": + if app == "heimdall": + cmnd = "docker stop heimdall" + status, output = subprocess.getstatusoutput(cmnd) entries = ["Home Assistant","Nginx Proxy Manager","Portainer","Roundcube","Authentik","Kestra"] for e in entries: cmnd = f"sqlite3 /share/docker_data/heimdall/config/www/app.sqlite \"SELECT url FROM items WHERE title = '{e}'\"" @@ -230,6 +232,9 @@ if _RESTORE: cmnd = f"sqlite3 /share/docker_data/heimdall/config/www/app.sqlite \"UPDATE items SET url = '{contents}' WHERE title = '{e}'\"" print(cmnd) + status, output = subprocess.getstatusoutput(cmnd) + cmnd = "docker start heimdall" + status, output = subprocess.getstatusoutput(cmnd) elif app == "nginx": print("Stopping docker") cmnd = "docker stop nginx-app-1"