Add Unifi Rollout
This commit is contained in:
parent
c4ec42f668
commit
92b386f75b
4
host_vars/unifi.yml
Normal file
4
host_vars/unifi.yml
Normal file
@ -0,0 +1,4 @@
|
||||
ansible_host: 5.9.220.118
|
||||
ansible_port: 22
|
||||
ansible_ssh_user: root
|
||||
ansible_python_interpreter: /usr/bin/python3
|
@ -18,6 +18,11 @@ all:
|
||||
freifunk-supernodes:
|
||||
hosts:
|
||||
vpn02:
|
||||
service_server:
|
||||
children:
|
||||
unifi:
|
||||
hosts:
|
||||
unifi:
|
||||
edge_router:
|
||||
hosts:
|
||||
edge1:
|
||||
|
@ -1,12 +1,13 @@
|
||||
- name: Repo Key Import
|
||||
ansible.builtin.shell: curl https://packages.openitcockpit.io/repokey.txt | sudo apt-key add
|
||||
- name: Add OITC GPG Key
|
||||
ansible.builtin.get_url:
|
||||
url: https://packages.openitcockpit.io/repokey.txt
|
||||
dest: /etc/apt/keyrings/openitcockpit-agent-keyring.asc
|
||||
|
||||
- name: Add specified repository into sources list
|
||||
ansible.builtin.apt_repository:
|
||||
repo: deb https://packages.openitcockpit.io/openitcockpit-agent/deb/stable deb main
|
||||
repo: "deb [signed-by=/etc/apt/keyrings/openitcockpit-agent-keyring.asc] https://packages.openitcockpit.io/openitcockpit-agent/deb/stable deb main"
|
||||
state: present
|
||||
|
||||
|
||||
- name: Install OITC-Agent
|
||||
apt: name={{ item }} state=latest update_cache=yes
|
||||
with_items:
|
||||
|
37
roles/21-unifi/tasks/main.yml
Normal file
37
roles/21-unifi/tasks/main.yml
Normal file
@ -0,0 +1,37 @@
|
||||
---
|
||||
- name: Install Packages for Unifi APT
|
||||
ansible.builtin.apt:
|
||||
name:
|
||||
- ca-certificates
|
||||
- apt-transport-https
|
||||
state: latest
|
||||
update_cache: yes
|
||||
|
||||
- name: Add MongoDB GPG Key
|
||||
ansible.builtin.get_url:
|
||||
url: https://www.mongodb.org/static/pgp/server-3.0.asc
|
||||
dest: /etc/apt/keyrings/mongodb-3.0.asc
|
||||
|
||||
- name: Add Unifi GPG Key
|
||||
ansible.builtin.get_url:
|
||||
url: https://dl.ui.com/unifi/unifi-repo.gpg
|
||||
dest: /etc/apt/trusted.gpg.d/unifi-repo.gpg
|
||||
|
||||
- name: Add MongoDB repository into sources list using specified filename
|
||||
ansible.builtin.apt_repository:
|
||||
repo: "deb [trusted=yes] http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.0 multiverse"
|
||||
state: present
|
||||
filename: mongodb
|
||||
|
||||
- name: Add Unifi repository into sources list using specified filename
|
||||
ansible.builtin.apt_repository:
|
||||
repo: deb https://www.ui.com/downloads/unifi/debian stable ubiquiti
|
||||
state: present
|
||||
filename: unifi
|
||||
|
||||
- name: Install Unifi via APT
|
||||
ansible.builtin.apt:
|
||||
name:
|
||||
- unifi
|
||||
state: latest
|
||||
update_cache: yes
|
11
system-setup-unifi.yml
Normal file
11
system-setup-unifi.yml
Normal file
@ -0,0 +1,11 @@
|
||||
# ansible-playbook -i hosts.yml system-setup-unifi.yml
|
||||
- name: System preperation
|
||||
hosts: service_server
|
||||
roles:
|
||||
#- 00-ubuntu-basic
|
||||
- 21-install-oitc
|
||||
|
||||
- name: Unifi Setup
|
||||
hosts: unifi
|
||||
roles:
|
||||
- 21-unifi
|
Loading…
Reference in New Issue
Block a user