custom-html/compose.yml

54 lines
1.6 KiB
YAML
Raw Permalink Normal View History

2021-10-12 07:20:19 +00:00
---
2020-10-06 18:48:21 +00:00
version: "3.8"
2021-10-12 07:20:19 +00:00
2020-10-06 18:48:21 +00:00
services:
app:
2023-11-09 17:35:58 +00:00
image: nginx:1.25.3
2020-10-06 18:48:21 +00:00
networks:
- proxy
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}"
2020-10-06 19:09:14 +00:00
# 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}"
2023-11-09 17:35:58 +00:00
- "coop-cloud.${STACK_NAME}.version=1.5.1+1.25.3"
2023-01-19 23:49:13 +00:00
- "backupbot.backup=true"
- "backupbot.backup.path=/usr/share/nginx/html"
environment:
2023-03-15 22:48:17 +00:00
- DEFAULT_CONF_FILE=/etc/nginx/conf.d/default.conf
- REDIRECT_FROM_PATH
- REDIRECT_TO_URL
- REDIRECT_TYPE
2020-10-06 19:09:14 +00:00
volumes:
- content:/usr/share/nginx/html
2020-12-27 13:46:53 +00:00
configs:
- source: nginx_default_conf
target: /etc/nginx/conf.d/default.conf
2021-04-05 00:07:21 +00:00
#healthcheck:
# test: ["CMD", "curl", "-f", "http://localhost"]
# interval: 30s
# timeout: 10s
# retries: 10
# start_period: 1m
2021-10-12 07:20:19 +00:00
2020-10-06 19:09:14 +00:00
volumes:
content:
2021-10-12 07:20:19 +00:00
2020-12-27 13:46:53 +00:00
configs:
nginx_default_conf:
name: ${STACK_NAME}_nginx_default_conf_${NGINX_DEFAULT_CONF_VERSION}
2023-03-15 22:48:17 +00:00
file: default.conf.tmpl
template_driver: golang
2021-10-12 07:20:19 +00:00
2020-10-06 18:48:21 +00:00
networks:
proxy:
external: true