refactor: use the properties system instead of the data dir for tracking whether a proxy should be stopped or started

This commit is contained in:
Jose Diaz-Gonzalez
2022-11-22 23:29:34 -05:00
parent 6fed37b408
commit 5fed0c45ac
7 changed files with 15 additions and 16 deletions

View File

@@ -8,7 +8,7 @@ trigger-caddy-pre-restore() {
declare desc="pre-restore the caddy proxy"
declare trigger="install"
if [[ ! -f "${DOKKU_LIB_ROOT}/data/caddy/caddy.started" ]]; then
if [[ "$(fn-plugin-property-get "caddy" "--global" "proxy-status")" == "stopped" ]]; then
return
fi