pelican/compose.yml

43 lines
1.4 KiB
YAML
Raw Normal View History

2020-10-26 19:29:30 +00:00
version: "3.8"
services:
app:
2023-01-31 06:16:21 +00:00
image: git.coopcloud.tech/coop-cloud-chaos-patchs/pelican:4.7.2
2020-10-26 20:15:35 +00:00
volumes:
- src:/site
- output:/site-generated
2021-04-04 23:06:47 +00:00
deploy:
labels:
2023-01-31 06:21:36 +00:00
- coop-cloud.${STACK_NAME}.version=0.1.1+4.7.2
2020-10-26 20:15:35 +00:00
web:
image: httpd:2.4
volumes:
- output:/usr/local/apache2/htdocs/:ro
2020-10-26 19:29:30 +00:00
networks:
- proxy
2020-10-26 20:15:35 +00:00
command: >
bash -c
"
sed -i '/LoadModule rewrite_module/s/^#//g' /usr/local/apache2/conf/httpd.conf &&
sed -i 's#AllowOverride [Nn]one#AllowOverride All#' /usr/local/apache2/conf/httpd.conf &&
httpd -DFOREGROUND"
2020-10-26 19:29:30 +00:00
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-26 20:15:35 +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}"
2021-04-04 23:06:47 +00:00
- coop-cloud.${STACK_NAME}.web.version=2.4-31ee85db
2020-10-26 20:15:35 +00:00
volumes:
src:
output:
2020-10-26 19:29:30 +00:00
networks:
proxy:
external: true