Created
October 7, 2020 12:10
-
-
Save diogopms/89f50411a01323de16c677f8700d1d35 to your computer and use it in GitHub Desktop.
unify-controller with traefik
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.7" | |
services: | |
unifi-controller: | |
image: linuxserver/unifi-controller:5.14.23-ls76 | |
container_name: unifi-controller | |
environment: | |
- PUID=1000 | |
- PGID=1000 | |
- TZ="Europe/Lisbon" | |
volumes: | |
- ./config:/config | |
ports: | |
- 3478:3478/udp | |
- 10001:10001/udp | |
- 8080:8080 | |
- 8443:8443 | |
restart: unless-stopped | |
labels: | |
- "traefik.enable=true" | |
- "traefik.http.routers.unifi.rule=Host(`<DOMAIN>`)" | |
- "traefik.http.routers.unifi.entrypoints=websecure" | |
- "traefik.http.routers.unifi.tls=true" | |
- "traefik.http.routers.unifi.tls.certresolver=lets-encr" | |
- "traefik.http.services.unifi.loadbalancer.server.port=8443" | |
- "traefik.http.services.unifi.loadbalancer.server.scheme=https" | |
- "traefik.docker.network=home" | |
- "traefik.http.middlewares.unifi.headers.sslredirect=true" | |
- "traefik.http.middlewares.unifi.headers.stsSeconds=315360000" | |
- "traefik.http.middlewares.unifi.headers.browserXSSFilter=true" | |
- "traefik.http.middlewares.unifi.headers.contentTypeNosniff=true" | |
- "traefik.http.middlewares.unifi.headers.forceSTSHeader=true" | |
- "traefik.http.middlewares.unifi.headers.STSIncludeSubdomains=true" | |
- "traefik.http.middlewares.unifi.headers.STSPreload=true" | |
- "traefik.http.middlewares.unifi.headers.frameDeny=true" | |
- "traefik.http.middlewares.unifi.headers.accessControlAllowCredentials=true" | |
- "traefik.http.middlewares.unifi.headers.SSLHost=<DOMAIN>" | |
networks: | |
default: | |
external: | |
name: home |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment