Skip to content

chore/container healthchecks - #2086

Open
alanpeixinho wants to merge 2 commits into
kernelci:mainfrom
profusion:chore/container-healthchecks
Open

chore/container healthchecks#2086
alanpeixinho wants to merge 2 commits into
kernelci:mainfrom
profusion:chore/container-healthchecks

Conversation

@alanpeixinho

Copy link
Copy Markdown
Contributor

What it is

  • Docker healthchecks for redis, backend, and proxy (staging + production compose)
  • GET /health/ liveness endpoint for the backend probe
  • Post-deploy SSH step reports container state, health, restarts, and image in the GHA job summary
  • Same table in Discord when deploy fails
  • Staging dashboard_db maps POSTGRES_* from DB_* (same as docker-compose-next.yml)
    Collect fails only if a service is missing or not running (exited 0 one-shots, e.g. dashboard
    rsync, are OK). starting / unhealthy are reported, not a job failure.

How to Test

  • docker compose up -d redis dashboard_db backendcurl -H 'Host: backend' http://localhost:8000/health/ and docker compose ps show backend/redis healthy
  • sh .github/scripts/deploy_collect_compose_status.sh docker-compose.yml prints the status table
  • After merge to main: staging deploy job summary includes the same table

Closes #2078

* set POSTGRES_USER, POSTGRES_PASSWORD, and POSTGRES_DB from DB_* in staging compose
* align with docker-compose-next.yml local-db profile

Signed-off-by: Alan Peixinho <alan.peixinho@profusion.mobi>
* add GET /health/ liveness endpoint for backend probes
* add redis, backend, and proxy healthchecks in staging and production compose
* collect compose container state over SSH after deploy
* publish status table to GitHub job summary and failure notifications

Signed-off-by: Alan Peixinho <alan.peixinho@profusion.mobi>
@felipebergamin

Copy link
Copy Markdown
Member

looking good. I want to run some tests running locally before approving

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve container health checks and post-deployment visibility

2 participants