taskchampion-sync-server/docker-compose.yml
Dustin J. Mitchell 65a3d806d7
Followup to the 0.5.0 release (#76)
* Document RELEASING.md process
* Bump version numbers
* Do not automatically produce GH releases, and do not build binaries to attach to them
* Only build docker images on tags
* Use the `latest` Docker image tag in the Docker-compose config
2024-12-15 22:51:57 -05:00

64 lines
1.6 KiB
YAML

volumes:
data:
services:
# Make the necessary subdirectories of the `data` volume, and set ownership of the
# `tss/taskchampion-sync-server` directory, as the server runs as user 100.
mkdir:
image: caddy:2-alpine
command: |
/bin/sh -c "
mkdir -p /data/caddy/data /data/caddy/config /data/tss/taskchampion-sync-server &&
chown -R 100:100 /data/tss/taskchampion-sync-server
"
volumes:
- type: volume
source: data
target: /data
read_only: false
volume:
nocopy: true
caddy:
image: caddy:2-alpine
restart: unless-stopped
ports:
- "80:80"
- "443:443"
volumes:
- type: volume
source: data
target: /data
read_only: false
volume:
nocopy: true
subpath: caddy/data
- type: volume
source: data
target: /config
read_only: false
volume:
nocopy: true
subpath: caddy/config
command: caddy reverse-proxy --from https://${TASKCHAMPION_SYNC_SERVER_HOSTNAME} --to http://tss:8080
depends_on:
mkdir:
condition: service_completed_successfully
tss:
image: ghcr.io/gothenburgbitfactory/taskchampion-sync-server:latest
restart: unless-stopped
volumes:
- type: volume
source: data
target: /tss
read_only: false
volume:
nocopy: true
subpath: tss
command: --data-dir /tss/taskchampion-sync-server --port 8080
environment:
- RUST_LOG=info
depends_on:
mkdir:
condition: service_completed_successfully