From 9a17ed957a8ebb377569f06aa18d3a61065dffa0 Mon Sep 17 00:00:00 2001 From: knoflook Date: Tue, 1 Oct 2024 16:26:46 +0200 Subject: [PATCH] feat: add httpd support --- .env.sample | 4 ++++ compose.httpd.yml | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 compose.httpd.yml diff --git a/.env.sample b/.env.sample index 90fb0e3..4d20287 100644 --- a/.env.sample +++ b/.env.sample @@ -32,3 +32,7 @@ SECRET_DB_PASSWORD_VERSION=v1 #SMTP_AUTH=on #SMTP_TLS=on #SECRET_SMTP_PASSWORD_VERSION=v1 + + +# Use httpd instead of nginx +#COMPOSE_FILE="$COMPOSE_FILE:compose.httpd.yml" diff --git a/compose.httpd.yml b/compose.httpd.yml new file mode 100644 index 0000000..cffd363 --- /dev/null +++ b/compose.httpd.yml @@ -0,0 +1,34 @@ +version: "3.8" +services: + frontend: + image: httpd:2.4.62 + networks: + - proxy + depends_on: + - app + 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}" + # 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}.frontend.version=1.20-c628b67d + volumes: + - site_content:/usr/local/apache2/htdocs/ + # configs: + # - source: httpd_default_conf + # target: /usr/local/apache2/conf/httpd.conf + + + #configs: + # httpd_default_conf: + # name: ${STACK_NAME}_httpd_default_conf_${HTTPD_DEFAULT_CONF_VERSION} + # file: httpd.conf + # template_driver: golang