Skip to content

Commit c912c8a

Browse files
committed
chore(scripts): update apply script for handling reloads via docker compose exec over remote admin API calls
1 parent 90db6ca commit c912c8a

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

scripts/apply

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ set -e
33
CONFIG_PATH=${CONFIG_PATH:-"./config/caddy/Caddyfile"}
44
CADDY_ADMIN=${CADDY_ADMIN:-"100.77.60.119:20241"}
55

6-
dotenvx run -f .env.production -- caddy reload \
7-
--config "${CONFIG_PATH}" \
8-
--address "${CADDY_ADMIN}"
6+
if [[ $FF_RELOAD_VIA_REMOTE_ADMIN_API != "" ]]; then
7+
dotenvx run -f .env.production -- caddy reload \
8+
--config "${CONFIG_PATH}" \
9+
--address "${CADDY_ADMIN}"
10+
else
11+
docker compose exec caddy reload --config /etc/caddy/Caddyfile
12+
fi

0 commit comments

Comments
 (0)