B. Blue Green a software delivery tutorial
Vol. I § Zero-downtime series § A series for junior developers
Zero-downtime delivery · 7 / 10 ·

The health check is the gate

The idle slot must answer GET /health before Caddy moves. If the check fails, the playbook stops. The live slot is left alone.

Slot playground · health-gate
readerCaddy :8080blue :18080 · upgreen :18081 · booting
The health check runs on the idle slot.
  1. The health check runs on the idle slot.
  2. The check fails. The switch stays closed. Blue stays live.
  3. The check passes. Only now may the switch move.
explainer · health
Explanation

The check passed. The Caddy route may move to green.

Change the explainer to health: fail. Watch blue keep the requests. That is why the gate exists.

Reader notes

Chapter discussion appears once Giscus is connected to the site repository.