diff --git a/scripts/install.sh b/scripts/install.sh index 2d40ab3..dbfa38f 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -201,7 +201,12 @@ for unit in evection-gunicorn evection-celery-worker evection-celery-beat; do "$APP_DIR/docs/deploy/${unit}.service" > "/etc/systemd/system/${unit}.service" done systemctl daemon-reload -systemctl enable --now evection-gunicorn evection-celery-worker evection-celery-beat +systemctl enable evection-gunicorn evection-celery-worker evection-celery-beat +# Not "enable --now": that only starts a service if it's stopped, so a +# re-run after a unit file changed (e.g. a new EVECTION_GUNICORN_BIND) +# would reload the daemon but leave the already-running process on its +# stale old ExecStart indefinitely. Always restart explicitly instead. +systemctl restart evection-gunicorn evection-celery-worker evection-celery-beat echo echo "==> Services installed. Checking status..."