AspireCloud/docker/traefik/docker-compose.yml
Chuck Adams ee312f2882
add traefik proxy and frankenphp service as alternative to fpm (#17)
* refactor: replace nginx with frankenphp

* fix: add git and zip to the docker image

* refactor: parameterize bin/{create,remove}-external-network.sh

+resilience in remove script

* feat: add traefik proxy

* feat: add traefik-up and traefik-down Makefile targets

* doc: add traefik section to README

* doc: fix thinko

* docs: update traefik README

add note that you still need to edit /etc/hosts

* refactor: docker-compose configs for both nginx and frankenphp

* fix: use correct path to Dockerfile in docker-compose.frankenphp.yml

* feat: switch web backends via environment var (default nginx)
2024-10-16 07:54:20 -06:00

19 lines
583 B
YAML

services:
traefik:
image: traefik:2.3 # an old but reliable version
restart: unless-stopped
ports:
- "${TRAEFIK_HTTP_PORT:-80}:80"
- "${TRAEFIK_HTTPS_PORT:-443}:443"
- "${TRAEFIK_DASHBOARD_PORT:-8080}:8080"
volumes:
- ${TRAEFIK_CONFIG_FILE:-./traefik.yaml}:/etc/traefik/traefik.yaml
- ${TRAEFIK_CONFIG_DIR:-./traefik-config.d}:/etc/traefik/traefik-config.d
- ${TRAEFIK_CERTS_DIR:-./certs}:/etc/traefik/certs
- /var/run/docker.sock:/var/run/docker.sock
networks:
- traefik
networks:
traefik:
external: true