Skip to content

Repository files navigation

🔧 Push'n'Pray

Light a candle for your deploy. Bless your CI with hope and memes 🙏

Example

Docker Image CI Demo


📆 What is this?

Push'n'Pray is a fun service that lets you "light a candle" before or after a release. It generates a blessed animated candle GIF with your message and a unique link you can share or embed in your Merge Request, Slack, or README.


⚙️ Features

  • 🕯️ Animated candle with flickering flame
  • ✍️ Custom message (emoji-safe, up to 100 characters)
  • 🌐 Shareable, cacheable image URL
  • 📎 Markdown embed code for Merge Requests
  • 🟣 Docker-ready + CI/CD friendly

🚀 How to use

  1. Visit the web UI (or call API)
  2. Enter a wish (e.g. “Please no 500 on prod 🙏”)
  3. Click "Submit candle"
  4. Embed the result:
![Blessed Candle](https://push-n-pray.tech-pioneer.info)

🟣 Deployment

Docker

Build locally:

docker build -t push-n-pray .
docker run -p 8080:8080 -e DATABASE_URL="postgres://user:pass@host:5432/dbname" push-n-pray

Or pull the prebuilt image from GHCR:

docker run -p 8080:8080 -e DATABASE_URL="postgres://user:pass@host:5432/dbname" ghcr.io/isqanderm/push-n-pray:latest

Visit http://localhost:8080

DATABASE_URL is required. On startup the server retries the connection with exponential backoff (handy for cold-start databases like Neon) and exits if Postgres stays unreachable.


💥 Environment Variables

Name Description Default
PORT Port to run the server 8080
DOMAIN Public base URL used to build image links (e.g. https://push-n-pray.tech-pioneer.info) (empty → relative URLs)
DATABASE_URL Postgres connection string (required) —
TRUSTED_PROXIES Comma-separated proxy IPs/CIDRs to trust for X-Forwarded-For (set to your LB/Cloudflare ranges when running behind a proxy, so per-IP rate limiting sees the real client) (empty → trust none, use direct peer IP)

🧪 API

GET /

Web UI with the candle form.

POST /candles

Create a new candle.

Form fields:

  • message — your wish or blessing (required, trimmed; truncated to 100 characters, emoji-safe)

Responses:

  • 200 (HTML) — preview with the image and a ready-to-copy Markdown embed
  • 400 — empty message
  • 429 — rate limit exceeded (per-IP, ~10 requests/min, burst 5)

GET /candles/:id/image

Returns the animated candle GIF for a given candle id.

  • 200 (image/gif) — the blessed candle
  • 404 — no candle with that id

Served with Cache-Control: public, max-age=31536000, immutable.


⚡ Caching

Candle images are immutable — a candle id maps to a deterministic GIF — so they carry a one-year immutable cache header and are safe to cache forever in browsers and at a CDN edge (no purging ever needed).

To offload generation to a CDN like Cloudflare, add a Cache Rule matching /candles/*/image with:

  • Cache eligibility: Eligible for cache (required — the extensionless path is treated as dynamic otherwise)
  • Cache key → Query string: Ignore all query strings (prevents ?x=random cache-busting from hammering the origin)

📅 GitHub Actions

This project includes a GitHub Action to build and publish Docker images to ghcr.io.

See .github/workflows/docker.yml


❤️ Credits

Made with memes, Go and love by your friendly DevOps priest.
Bless your pipelines. Amen. 🙏

Release Candle

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages