head-vps/doco-cd/compose.yaml

42 lines
1.7 KiB
YAML

services:
doco-cd:
# Pinned by tag and digest: doco-cd upgrades itself from this file, so a bump is a reviewed commit.
image: ghcr.io/kimdre/doco-cd:0.132.0@sha256:ed22583456c60c88c5cabdb47803aa0ab51284f00d70d5bb63fa56b223fa250a
restart: unless-stopped
# No container_name and no host port: lets the self-update hand over with zero downtime.
environment:
TZ: Europe/Zurich
SELF_UPDATE_ENABLED: "true"
SELF_UPDATE_STRATEGY: auto
# One deployment at a time: parallel Vite builds exhaust the 3.8 GB host (a build was cancelled).
MAX_CONCURRENT_DEPLOYMENTS: "1"
# Every repository doco-cd deploys from: Forgejo's repositories, read straight from disk (doco-cd's
# answer to the forge deploying itself: no token, and deploys keep working while Forgejo is down).
# `watch` (on by default) deploys as soon as a push lands, the interval is only a fallback.
POLL_CONFIG: |
- url: /repos/headpoolnumerique/head-vps.git
reference: main
interval: 3600
- url: /repos/headpoolnumerique/storytellurx.git
reference: main
interval: 3600
- url: /repos/headpoolnumerique/storytellurx-v1.git
reference: main
interval: 3600
- url: /repos/headpoolnumerique/fuckingtech.git
reference: main
interval: 3600
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- data:/data
- ${GIT_ROOT}:/repos:ro
# The host age key, for app builds that decrypt secrets (`build.secrets` reads it client-side).
- /etc/head-vps:/etc/head-vps:ro
healthcheck:
interval: 10s
timeout: 5s
start_period: 15s
retries: 3
volumes:
data: