-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsite.yml
More file actions
64 lines (57 loc) · 1.87 KB
/
site.yml
File metadata and controls
64 lines (57 loc) · 1.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
---
# Site Playbook: Self-Hosted Identity Stack
#
# Verwendung:
# Alles: ansible-playbook -i inventory site.yml
# Nur Zertifikate: ansible-playbook -i inventory site.yml --tags tls
# Nur Docker-Stack: ansible-playbook -i inventory site.yml --tags docker-stack
# Post NextCloud Setup : ansible-playbook -i inventory site.yml --tags nextcloud-postsetup
# Nur CA verteilen: ansible-playbook -i inventory site.yml --tags trust-ca
# Nur Clients: ansible-playbook -i inventory site.yml --tags lldap-client
# --- Phase 1: TLS-Zertifikate ---
- name: TLS-Zertifikate bereitstellen
hosts: server
become: true
tags: tls
tasks:
- name: Selbstsignierte Zertifikate erstellen
ansible.builtin.include_role:
name: tls-certs
when: tls_mode == "selfsigned"
- name: Let's Encrypt Zertifikat per Certbot
ansible.builtin.include_role:
name: tls-certbot
when: tls_mode == "certbot"
- name: Vorhandene Zertifikate pruefen
ansible.builtin.include_role:
name: tls-existing
when: tls_mode == "existing"
# --- Phase 2: Docker-Stack deployen ---
- name: Docker-Stack deployen (LLDAP + Pocket ID + Nextcloud + Caddy)
hosts: server
become: true
tags: docker-stack
roles:
- docker-stack
# --- Phase 3: CA-Zertifikat auf Clients verteilen ---
- name: CA-Zertifikat auf Clients verteilen
hosts: clients
become: true
tags: trust-ca
roles:
- trust-ca
# --- Phase 4: LLDAP-Clients einrichten ---
- name: LLDAP-Clients einrichten (SSSD + FIDO2-SSH)
hosts: clients
become: true
tags: lldap-client
roles:
- lldap-client
# --- Phase 5: Nextcloud Post-Setup ---
- name: Nextcloud Post-Setup (nach manuellem Admin-Account)
hosts: server
become: true
tags: nextcloud-postsetup
tasks:
- name: Nextcloud Nacharbeiten
ansible.builtin.include_tasks: roles/docker-stack/tasks/start-nextcloud.yml