generated from coop-cloud/example
58 lines
1.5 KiB
YAML
58 lines
1.5 KiB
YAML
---
|
|
version: "3.8"
|
|
|
|
services:
|
|
app:
|
|
image: nginx:1.21.0
|
|
environment:
|
|
- TEST_ENV_STANZA=DING # should be removed
|
|
networks:
|
|
- proxy
|
|
volumes:
|
|
- test-volume:/var/www
|
|
secrets:
|
|
- test_pass_one
|
|
- test_pass_two
|
|
deploy:
|
|
restart_policy:
|
|
condition: on-failure
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=80"
|
|
- "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=0.3.1+1.21.0"
|
|
- "coop-cloud.${STACK_NAME}.timeout=${TIMEOUT:-120}"
|
|
|
|
- "backupbot.backup=true"
|
|
- "backupbot.backup.path=/etc/nginx/"
|
|
- "backupbot.backup.pre-hook=echo 'foo'"
|
|
- "backupbot.backup.post-hook=echo 'bar'"
|
|
|
|
- "backupbot.restore=true"
|
|
- "backupbot.restore.pre-hook=echo 'baz'"
|
|
- "backupbot.restore.post-hook=echo 'bing'"
|
|
healthcheck:
|
|
test: ["CMD", "curl", "-f", "http://localhost"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 10
|
|
start_period: 1m
|
|
|
|
secrets:
|
|
test_pass_one:
|
|
external: true
|
|
name: ${STACK_NAME}_test_pass_one_${SECRET_TEST_PASS_ONE_VERSION} # should be removed
|
|
test_pass_two:
|
|
external: true
|
|
name: ${STACK_NAME}_test_pass_two_${SECRET_TEST_PASS_TWO_VERSION}
|
|
|
|
volumes:
|
|
test-volume:
|
|
|
|
networks:
|
|
proxy:
|
|
external: true
|