install.sh: restart capture services instead of enable --now

enable --now only starts a service that is not yet running — it leaves
an already-running service untouched, so changes to .env credentials
are never picked up without a manual restart.

Switching to enable + restart means every install.sh run brings capture
services in sync with the current sky-cam.conf and .env: new cameras
start, reconfigured cameras restart, and nothing needs manual follow-up.

https://claude.ai/code/session_01C4jbd3waXG3eKZYbGUjLUQ
This commit is contained in:
Claude
2026-04-21 18:28:44 +00:00
parent 9707e5ca37
commit c5474714be
+5 -3
View File
@@ -256,9 +256,11 @@ echo ""
$SC daemon-reload
for svc in "${capture_services[@]}"; do
$SC enable --now "${svc}.service" \
&& echo " enabled + started ${svc}.service" \
|| echo " WARNING: could not enable ${svc}.service"
if $SC enable "${svc}.service" && $SC restart "${svc}.service"; then
echo " enabled + started ${svc}.service"
else
echo " WARNING: could not enable/start ${svc}.service"
fi
done
for timer in "${timers[@]}"; do