Fix boot-time bringup aborting on slow crowdsec start #169
No reviewers
Labels
No labels
audit-work
bug
docs
general-admin
major-upgrade
needs-vps-sync
new-service
on-hold
outside-work
post-podman
renovate
upstream
vps
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
mysticalsoap/docker!169
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/boot-crowdsec-health"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem: On today's cold boot,
docker-compose-boot.servicefailed: crowdsec's entrypoint runs a hub update plus ~20 data-file downloads before the LAPI starts listening, which blew its health budget (30s start_period + 5×10s retries ≈ 73s). Compose--waitdeclared it unhealthy, traefik'sdepends_onaborted, andjust upexited 1 — traefik and every later stack never started until a manual re-run.Fix: Raise crowdsec's healthcheck
start_periodto 300s (a success during start_period still flips it healthy immediately, so fast starts cost nothing), and let the boot unit retry withRestart=on-failure/RestartSec=60(capped at 3 tries per 30min).RemainAfterExit=yesdropped — systemd refuses it in combination withRestart=.Verification:
just up infrarecreated crowdsec with the new healthcheck (start_period=5m0sconfirmed via inspect); crowdsec and traefik both healthy, traefik not restarted. Unit change takes effect at next boot;sudo systemctl daemon-reloadstill pending on the host.🤖 Generated with Claude Code
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.