agora/compose.yml

76 lines
2.1 KiB
YAML

---
version: "3.8"
services:
app:
environment:
- AGORA_USER=$AGORA_USER
- AGORA_PATH=$AGORA_PATH
$AGORA_PATH
- AGORA_GIT=$AGORA_GIT
image: git.coopcloud.tech/flancian/agora-server
volumes:
- data:$AGORA_PATH
ports:
- 5017:5017
networks:
- proxy
deploy:
restart_policy:
condition: on-failure
labels:
- "traefik.enable=true"
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=5017"
- "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}"
## Redirect from EXTRA_DOMAINS to DOMAIN
#- "traefik.http.routers.${STACK_NAME}.middlewares=${STACK_NAME}-redirect"
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLForceHost=true"
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
- "coop-cloud.${STACK_NAME}.version="
# Disabling health checks during development as per https://docs.coopcloud.tech/maintainers/handbook/.
# healthcheck:
# test: ["CMD", "curl", "-f", "http://localhost"]
# interval: 30s
# timeout: 10s
# retries: 10
# start_period: 1m
bridge:
environment:
- AGORA_USER=$AGORA_USER
- AGORA_PATH=$AGORA_PATH
$AGORA_PATH
- AGORA_GIT=$AGORA_GIT
image: git.coopcloud.tech/flancian/agora-bridge
volumes:
- data:$AGORA_PATH
deploy:
restart_policy:
delay: 30s
# This is meant to run once at the seeding of the Agora, when the AGORA_ROOT (volume) is found empty.
# It will clone a git repository into the designated location.
bootstrap:
environment:
- AGORA_USER=$AGORA_USER
- AGORA_PATH=$AGORA_PATH
$AGORA_PATH
- AGORA_GIT=$AGORA_GIT
image: git.coopcloud.tech/flancian/agora-bridge
command: |
bash -c
"git clone $AGORA_GIT $AGORA_PATH;
cd $AGORA_PATH && git pull"
volumes:
- data:$AGORA_PATH
networks:
proxy:
external: true
volumes:
data: