mirror of
https://github.com/JamesTurland/JimsGarage.git
synced 2024-11-21 15:30:19 +00:00
update
This commit is contained in:
parent
e217e74db4
commit
90355c354c
2 changed files with 64 additions and 0 deletions
62
Unifi-Controller/docker-compose.yaml
Normal file
62
Unifi-Controller/docker-compose.yaml
Normal file
|
@ -0,0 +1,62 @@
|
||||||
|
---
|
||||||
|
version: "2.1"
|
||||||
|
services:
|
||||||
|
unifi-network-application:
|
||||||
|
image: lscr.io/linuxserver/unifi-network-application:latest
|
||||||
|
container_name: unifi-network-application
|
||||||
|
environment:
|
||||||
|
- PUID=1000
|
||||||
|
- PGID=1000
|
||||||
|
- TZ=Etc/UTC
|
||||||
|
- MONGO_USER=unifi
|
||||||
|
- MONGO_PASS=5nHgg3G0cH9d
|
||||||
|
- MONGO_HOST=unifi-db
|
||||||
|
- MONGO_PORT=27017
|
||||||
|
- MONGO_DBNAME=unifi
|
||||||
|
- MEM_LIMIT=1024 #optional
|
||||||
|
- MEM_STARTUP=1024 #optional
|
||||||
|
# - MONGO_TLS= #optional
|
||||||
|
# - MONGO_AUTHSOURCE= #optional
|
||||||
|
volumes:
|
||||||
|
- /home/ubuntu/docker/unifi-controller:/config
|
||||||
|
ports:
|
||||||
|
- 8443:8443
|
||||||
|
- 3478:3478/udp
|
||||||
|
- 10001:10001/udp
|
||||||
|
- 8080:8080
|
||||||
|
- 1900:1900/udp #optional
|
||||||
|
- 8843:8843 #optional
|
||||||
|
- 8880:8880 #optional
|
||||||
|
- 6789:6789 #optional
|
||||||
|
- 5514:5514/udp #optional
|
||||||
|
labels:
|
||||||
|
- "traefik.enable=true"
|
||||||
|
- "traefik.http.routers.unifi.entrypoints=http"
|
||||||
|
- "traefik.http.routers.unifi.rule=Host(`unifi.jimsgarage.co.uk`)"
|
||||||
|
- "traefik.http.middlewares.unifi-https-redirect.redirectscheme.scheme=https"
|
||||||
|
- "traefik.http.routers.unifi.middlewares=unifi-https-redirect"
|
||||||
|
- "traefik.http.routers.unifi-secure.entrypoints=https"
|
||||||
|
- "traefik.http.routers.unifi-secure.rule=Host(`unifi.jimsgarage.co.uk`)"
|
||||||
|
- "traefik.http.routers.unifi-secure.tls=true"
|
||||||
|
- "traefik.http.routers.unifi-secure.service=unifi"
|
||||||
|
- "traefik.http.services.unifi.loadbalancer.server.port=8443"
|
||||||
|
- "traefik.http.services.unifi.loadbalancer.server.scheme=https"
|
||||||
|
- "traefik.docker.network=proxy"
|
||||||
|
networks:
|
||||||
|
proxy:
|
||||||
|
unifi:
|
||||||
|
restart: unless-stopped
|
||||||
|
unifi-db:
|
||||||
|
image: docker.io/mongo:4.4
|
||||||
|
container_name: unifi-db
|
||||||
|
volumes:
|
||||||
|
- /home/ubuntu/docker/unifi-controller-db:/data/db
|
||||||
|
- /home/ubuntu/docker-compose/unifi-controller/init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js:ro
|
||||||
|
networks:
|
||||||
|
unifi:
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
networks:
|
||||||
|
proxy:
|
||||||
|
external: true
|
||||||
|
unifi:
|
2
Unifi-Controller/init-mongo.js
Normal file
2
Unifi-Controller/init-mongo.js
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
db.getSiblingDB("unifi").createUser({user: "unifi", pwd: "5nHgg3G0cH9d", roles: [{role: "dbOwner", db: "unifi"}]});
|
||||||
|
db.getSiblingDB("unifi_stat").createUser({user: "unifi", pwd: "5nHgg3G0cH9d", roles: [{role: "dbOwner", db: "unifi_stat"}]});
|
Loading…
Reference in a new issue