| Filename | Latest commit message | Latest commit date |
|---|---|---|
|
All checks were successful
validate / compose (push) Successful in 7s
## Summary
`bugsink.esle.fi` returns `503 no available server`. The `web` container has
crash-looped since the 2026-10-23 deploy, so Traefik has no router for the host
and Coolify's catch-all router answers instead.
## Root cause
Coolify reads `SERVICE_URL_<NAME>` as a compose service name. The compose file
used `SERVICE_URL_BUGSINK`, but the service is `web`:
- Coolify writes `SERVICE_URL_WEB` to the deploy's `.env`, not
`SERVICE_URL_BUGSINK`, so `BASE_URL=${SERVICE_URL_BUGSINK}` rendered empty.
Bugsink's startup check then fails with `bsmain.W003 The BASE_URL setting
must be a valid URL` and the container exits 1.
- The `_8000` suffix never reached the `web` domain, so its Traefik router has
no `loadbalancer.server.port` label. The image declares no `EXPOSE`, so
Traefik would drop the container with `port is missing` even once it started.
CI stubbed `SERVICE_URL_BUGSINK` — a variable Coolify never writes — which hid
both failures.
## Changes
- **fix: name the domain variable after the web service** —
`BASE_URL=${SERVICE_URL_WEB}`, and `expose: "8000"` on `web`. Coolify 4.5.3
uses the first `expose` entry as the routing port for any domain that names
none, including domains edited in the UI later. CI stub renamed; README
updated.
- **fix: point the db healthcheck at the real database** — `pg_isready` now
passes `-d ${POSTGRES_DB:-bugsink}`. Without it, Postgres logged
`FATAL: database "<user>" does not exist` on every 5-second probe, while the
probe itself still passed.
The credential variables (`SERVICE_USER_BUGSINK`, `SERVICE_PASSWORD_*`) are
unchanged: renaming them would generate credentials the existing database
rejects.
## Verification
- Rendered with a `.env` shaped like Coolify's: before, `BASE_URL=''` and no
exposed port; after, `BASE_URL=https://bugsink.esle.fi` and `expose: 8000`.
- `docker compose config --quiet` with the CI stubs: exit 0, no warnings.
- Against the live db container: the new probe exits 0, and a 10-probe burst
logs no `FATAL` lines (the old form logs 10).
- actionlint and editorconfig-checker: clean. yamllint and prettier (defaults;
neither is configured in this repo): no new findings, pre-existing ones
unchanged.
## After merge
Redeploy in Coolify. Expected: `web` reports `Up (healthy)`, its router labels
include `loadbalancer.server.port=8000`, and `https://bugsink.esle.fi` serves
Bugsink.
Optional cleanup in Coolify: the stale `SERVICE_URL_BUGSINK*` and
`SERVICE_FQDN_BUGSINK*` environment variables.
Reviewed-on: #7
|
||
| .forgejo/workflows | ||
| docs/audit/findings | ||
| docker-compose.yaml | ||
| LICENSE | ||
| README.md | ||
| renovate.json | ||
coolify-bugsink
Bugsink (Postgres) as a Coolify Docker Compose resource.
Coolify ships a built-in Bugsink template, but it uses MySQL and an unpinned image. This is the upstream Postgres sample adapted to Coolify.
Deploy
- Coolify → project → + New → Docker Compose → point at this repo.
- Set
BUGSINK_ADMIN_EMAIL. It is marked required, so it appears at the top of the environment list. Do this before the first deploy — see below. - Deploy. Coolify generates the domain and all secrets.
- Log in with that email and the generated
SERVICE_PASSWORD_ADMIN, visible under Environment Variables.
What Coolify fills in
| Variable | Source |
|---|---|
SERVICE_URL_WEB |
The web service's domain; the name must match the compose service |
BASE_URL |
SERVICE_URL_WEB |
SECRET_KEY |
SERVICE_PASSWORD_64_BUGSINK (64 chars; Bugsink requires at least 50) |
SERVICE_USER_BUGSINK / SERVICE_PASSWORD_BUGSINK |
Postgres credentials, shared by both services |
SERVICE_PASSWORD_ADMIN |
Initial superuser password |
The proxy reaches Bugsink on port 8000 through expose on the web service,
so a domain added or edited in Coolify's UI needs no :8000.
Yours to set
| Variable | Default |
|---|---|
BUGSINK_ADMIN_EMAIL |
admin@example.org — required; first deploy only |
POSTGRES_DB |
bugsink — first deploy only |
BEHIND_HTTPS_PROXY=true assumes you serve Bugsink over HTTPS, which is
Coolify's default. Flip it if you don't.
First deploy only
BUGSINK_ADMIN_EMAIL, POSTGRES_DB, SERVICE_USER_BUGSINK, and
SERVICE_PASSWORD_BUGSINK are consumed once, when the stack initialises.
Bugsink creates the superuser only if none exists; Postgres reads its
credentials only when it initialises an empty data directory. Editing any of
them later in Coolify's UI changes what the web container sends without
changing what the database expects, so the web container crash-loops on
authentication while Postgres keeps reporting healthy.
Rotating secrets
To change the database password after deployment, change it in Postgres first:
# in Coolify's terminal for the db container
psql -U "$POSTGRES_USER" -d "$POSTGRES_DB" \
-c "ALTER USER \"$POSTGRES_USER\" WITH PASSWORD 'new-password';"
Then update SERVICE_PASSWORD_BUGSINK in Coolify to match and redeploy.
To change the admin password, use Bugsink's own UI, or
manage.py changepassword in the web container. Rotating
SERVICE_PASSWORD_ADMIN in Coolify has no effect on an existing user.
Keep replacement secrets alphanumeric
Two secrets are parsed, not just passed: SERVICE_PASSWORD_BUGSINK goes into
DATABASE_URL and SERVICE_PASSWORD_ADMIN is split on :. Coolify's
SERVICE_PASSWORD_* generator is symbol-free, so the defaults are safe. If you
replace either by hand, keep it alphanumeric — :, @, /, and # corrupt
the value, and neither failure names the cause.
Sending events
Point a Sentry SDK at the DSN from Bugsink's UI. Any Sentry SDK works.
License
MIT — see LICENSE.