forked from Netz39_Admin/netz39-infra-ansible
Compare commits
No commits in common. "419b89af374c3b8db0099fddb348f740ca5ebaef" and "911fe28e0630a171317981e03e6c497698eca3c8" have entirely different histories.
419b89af37
...
911fe28e06
3 changed files with 30 additions and 29 deletions
3
main.yml
3
main.yml
|
@ -39,6 +39,3 @@
|
||||||
|
|
||||||
- name: Pottwal specific setup
|
- name: Pottwal specific setup
|
||||||
import_playbook: pottwal.yml
|
import_playbook: pottwal.yml
|
||||||
|
|
||||||
- name: Unifi specific setup
|
|
||||||
import_playbook: unifi.yml
|
|
||||||
|
|
27
roles/unifi-controller-docker/tasks/main.yml
Normal file
27
roles/unifi-controller-docker/tasks/main.yml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
---
|
||||||
|
- name: Install python docker package
|
||||||
|
apt:
|
||||||
|
name: python3-docker
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Setup the docker container for unifi-controller
|
||||||
|
docker_container:
|
||||||
|
name: unifi-controller
|
||||||
|
image: "jacobalberty/unifi:v6.5.55"
|
||||||
|
state: started
|
||||||
|
restart_policy: unless-stopped
|
||||||
|
container_default_behavior: no_defaults
|
||||||
|
env:
|
||||||
|
TZ: "Europe/Berlin"
|
||||||
|
ports:
|
||||||
|
# These fixed ports are needed.
|
||||||
|
# https://help.ui.com/hc/en-us/articles/218506997-UniFi-Ports-Used
|
||||||
|
- "8080:8080/tcp" # Device command/control
|
||||||
|
- "8443:8443/tcp" # Web interface + API
|
||||||
|
- "8843:8843/tcp" # HTTPS portal
|
||||||
|
- "8880:8880/tcp" # HTTP portal
|
||||||
|
- "3478:3478/udp" # STUN service
|
||||||
|
- "6789:6789/tcp" # Speed Test (unifi5 only)
|
||||||
|
volumes:
|
||||||
|
- "/srv/docker/unifi-controller/data:/unifi/data"
|
||||||
|
- "/srv/docker/unifi-controller/log:/unifi/log"
|
29
unifi.yml
29
unifi.yml
|
@ -4,29 +4,6 @@
|
||||||
become: true
|
become: true
|
||||||
vars:
|
vars:
|
||||||
ansible_python_interpreter: /usr/bin/python3
|
ansible_python_interpreter: /usr/bin/python3
|
||||||
tasks:
|
roles:
|
||||||
- name: Install python docker package
|
- unifi-controller-docker
|
||||||
apt:
|
tasks: []
|
||||||
name: python3-docker
|
|
||||||
state: present
|
|
||||||
- name: Setup the docker container for unifi-controller
|
|
||||||
docker_container:
|
|
||||||
name: unifi-controller
|
|
||||||
image: "jacobalberty/unifi:v6.5.55"
|
|
||||||
state: started
|
|
||||||
restart_policy: unless-stopped
|
|
||||||
container_default_behavior: no_defaults
|
|
||||||
env:
|
|
||||||
TZ: "Europe/Berlin"
|
|
||||||
# These fixed ports are needed.
|
|
||||||
# https://help.ui.com/hc/en-us/articles/218506997-UniFi-Ports-Used
|
|
||||||
ports:
|
|
||||||
- "8080:8080/tcp" # Device command/control
|
|
||||||
- "8443:8443/tcp" # Web interface + API
|
|
||||||
- "8843:8843/tcp" # HTTPS portal
|
|
||||||
- "8880:8880/tcp" # HTTP portal
|
|
||||||
- "3478:3478/udp" # STUN service
|
|
||||||
- "6789:6789/tcp" # Speed Test (unifi5 only)
|
|
||||||
volumes:
|
|
||||||
- "/srv/data/unifi-controller/data:/unifi/data"
|
|
||||||
- "/srv/data/unifi-controller/log:/unifi/log"
|
|
||||||
|
|
Loading…
Reference in a new issue