---
version: "2"
services:
unifi-controller:
image: linuxserver/unifi-controller:8.0.24
container_name: unifi-controller
restart: unless-stopped
environment:
- PUID=1000 # for UserID
- PGID=1000 # for GroupID
- MEM_LIMIT=1024M # Optionally change the Java memory limit (-Xmx) (default is 1024M).
volumes:
- /host/path/to/config:/config # All Unifi data stored here
ports:
- 10001:10001/udp # Required for AP discovery
- 8880:8880/tcp # Unifi guest portal HTTP redirect port
- 8843:8843/tcp # Unifi guest portal HTTPS redirect port
- 8443:8443/tcp # Unifi web admin port
- 8080:8080/tcp # Required for device communication
- 6789:6789/tcp # For mobile throughput test
- 5514:5514/tcp # Remote syslog port
- 3478:3478/udp # Unifi STUN port
- 1900:1900/udp # Required for Make controller discoverable on L2 network option