chore: upgrade to 3.1.0+v2.0.0
Some checks failed
cc-ci/testme cc-ci: failure

Minor bump — no operator action required (Postgres/ClickHouse changes are automatic).

- Postgres: use pgautoupgrade/pgautoupgrade:18-alpine in place of the custom
  pg_upgrade entrypoint. The existing cluster is upgraded in place automatically
  on deploy; PGDATA pinned to the legacy path; adds a pg_isready healthcheck.
  Removes entrypoint.postgres.sh.tmpl and DB_ENTRYPOINT_VERSION.
- ClickHouse backup fetch: cache the clickhouse-backup binary on the persistent
  volume and retry with backoff to avoid the download crash-loop. The tool is
  required — if it can't be installed after retries the entrypoint aborts and
  the server does not start, rather than coming up without backup/restore.
- Add CLICKHOUSE_DATABASE_URL; bump the clickhouse entrypoint config version.
- Remove a stray broken link reference in the README.
This commit is contained in:
notplants
2026-06-09 15:46:28 +00:00
parent da159375d8
commit 50a3715caa
5 changed files with 48 additions and 68 deletions

View File

@ -12,6 +12,7 @@ services:
- BASE_URL=https://$DOMAIN
- SECRET_KEY_BASE
- DATABASE_URL=postgres://plausible:plausible@${STACK_NAME}_db:5432/plausible
- CLICKHOUSE_DATABASE_URL=http://${STACK_NAME}_plausible_events_db:8123/plausible_events_db
- SMTP_HOST_ADDR
- MAILER_EMAIL
- SMTP_HOST_PORT
@ -32,23 +33,24 @@ services:
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS})"
- "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
- "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
- coop-cloud.${STACK_NAME}.version=3.0.1+v2.0.0
- coop-cloud.${STACK_NAME}.version=3.1.0+v2.0.0
db:
image: postgres:13.12
configs:
- source: db_entrypoint
target: /docker-entrypoint.sh
mode: 0555
# Custom docker entrypoint to handle major Postgres version upgrades
image: pgautoupgrade/pgautoupgrade:18-alpine
volumes:
- db-data:/var/lib/postgresql/data
entrypoint: /docker-entrypoint.sh
environment:
# pin legacy PGDATA so the existing cluster on the volume is upgraded in place, not re-init'd
- PGDATA=/var/lib/postgresql/data
- POSTGRES_USER=plausible
- POSTGRES_PASSWORD=plausible
- POSTGRES_DB=plausible
networks:
- internal
healthcheck:
test: ["CMD-SHELL", "pg_isready -U plausible -d plausible"]
interval: 5s
timeout: 5s
retries: 60
deploy:
labels:
backupbot.backup: "true"
@ -98,10 +100,6 @@ configs:
clickhouse-user-config:
name: ${STACK_NAME}_clickhouse_user_config_${CLICKHOUSE_USER_CONF_VERSION}
file: clickhouse-user-config.xml
db_entrypoint:
name: ${STACK_NAME}_db_entrypoint_${DB_ENTRYPOINT_VERSION}
file: entrypoint.postgres.sh.tmpl
template_driver: golang
clickhouse_entrypoint:
name: ${STACK_NAME}_clickhouse_entrypoint_${CLICKHOUSE_ENTRYPOINT_VERSION}
file: entrypoint.clickhouse.sh