Grundstuktur erstellt.

This commit is contained in:
Frank Agerholm 2026-07-09 21:54:41 +02:00
commit db6f5ac31a
No known key found for this signature in database
15 changed files with 67 additions and 0 deletions

3
.gitignore vendored Normal file
View file

@ -0,0 +1,3 @@
ansible.log
ansible.cfg
.vaultpass

24
ansible.cfg.dist Normal file
View file

@ -0,0 +1,24 @@
[defaults]
inventory = ./inventory/demo/
roles_path = ./roles
collections_path = ./collections
log_path = ansible.log
# Create vault-file:
# read -s P
# printf "%s" "$P" > .vaultpass
#vault_password_file = ./.vaultpass
ansible_managed = Ansible managed: {file}
[inventory]
unparsed_is_failed = True
[ssh_connection]
pipelining = True
ssh_args = -o ControlMaster=auto -o ControlPersist=600s
timeout = 10
control_path = %(directory)s/%%h-%%r

0
collections/.gitkeep Normal file
View file

View file

@ -0,0 +1,3 @@
---
ansible_host: 192.0.2.10
#ansible_user: ansible

View file

@ -0,0 +1,3 @@
---
ansible_host: 192.0.2.20
#ansible_user: ansible

View file

@ -0,0 +1,3 @@
---
ansible_host: 192.0.2.30
#ansible_user: ansible

7
inventory/demo/hosts Normal file
View file

@ -0,0 +1,7 @@
[loadbalancer]
server1.example.com
[webserver]
server2.example.com
server3.example.com

9
roles/haproxy/README.md Normal file
View file

@ -0,0 +1,9 @@
# haproxy
## Aufgaben der Rolle
- Installation der haproxy-Software
- Konfigdatei aus Template erzeugen und auf Zielsystem speichern
- Systemd Service aktivieren und starten
- Wenn die Konfigdatei sich ändert, soll ein Restart des haproxy erfolgen

View file

@ -0,0 +1 @@
---

View file

@ -0,0 +1 @@
---

View file

11
roles/nginx/README.md Normal file
View file

@ -0,0 +1,11 @@
# nginx
## Aufgaben der Rolle
- Installation von nginx
- Aktivieren und Starten des Services
- Konfigdatei aus Template erzeugen
- Verzeichnis für virtualhosts anlegen (vhosts.d)
- Wenn sich eine Konfigdatei ändert, soll nginx neu gestartet werden

View file

@ -0,0 +1 @@
---

View file

@ -0,0 +1 @@
---

View file