From 495b61c1d15a59cccdd0bec89b00710849541f75 Mon Sep 17 00:00:00 2001 From: Bert-Jan Fikse Date: Fri, 23 Jan 2026 10:41:30 +0100 Subject: [PATCH] chore: switch to yaml inventory waaaay better readability --- inventories/vagrant/hosts.ini | 45 ------------------------- inventories/vagrant/hosts.yml | 62 +++++++++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+), 45 deletions(-) delete mode 100644 inventories/vagrant/hosts.ini create mode 100644 inventories/vagrant/hosts.yml diff --git a/inventories/vagrant/hosts.ini b/inventories/vagrant/hosts.ini deleted file mode 100644 index fcea02f..0000000 --- a/inventories/vagrant/hosts.ini +++ /dev/null @@ -1,45 +0,0 @@ -# This file defines the group structure for vagrant VMs -# Fixed IPs are defined in the Vagrantfile -# Additional host-specific variables should go in host_vars/ -# Group-specific variables should go in group_vars/ - -[all_servers] -dmz ansible_host=192.168.56.10 ansible_ssh_private_key_file=.vagrant/machines/dmz/libvirt/private_key ansible_user=vagrant -backend ansible_host=192.168.56.11 ansible_ssh_private_key_file=.vagrant/machines/backend/libvirt/private_key ansible_user=vagrant -backend2 ansible_host=192.168.56.12 ansible_ssh_private_key_file=.vagrant/machines/backend2/libvirt/private_key ansible_user=vagrant - -# Backend servers that host application services -[backend_servers] -backend -backend2 - -# Reverse proxy servers in DMZ (public-facing, file provider mode) -[traefik_servers_dmz] -dmz - -# Reverse proxy servers on backend (docker provider mode) -[traefik_servers_backend] -backend -backend2 - -# All reverse proxy servers -[traefik_servers:children] -traefik_servers_dmz -traefik_servers_backend - -# Application servers -[httpbin_servers] -backend -backend2 - -[keycloak_servers] -backend - -[authentik_servers] -backend - -[garage_servers] -backend - -[nextcloud_servers] -backend \ No newline at end of file diff --git a/inventories/vagrant/hosts.yml b/inventories/vagrant/hosts.yml new file mode 100644 index 0000000..e3bf998 --- /dev/null +++ b/inventories/vagrant/hosts.yml @@ -0,0 +1,62 @@ +--- +all: + children: + all_servers: + hosts: + dmz: + ansible_host: 192.168.56.10 + ansible_ssh_private_key_file: .vagrant/machines/dmz/libvirt/private_key + ansible_user: vagrant + backend: + ansible_host: 192.168.56.11 + ansible_ssh_private_key_file: .vagrant/machines/backend/libvirt/private_key + ansible_user: vagrant + backend2: + ansible_host: 192.168.56.12 + ansible_ssh_private_key_file: .vagrant/machines/backend2/libvirt/private_key + ansible_user: vagrant + + # Backend servers that host application services + backend_servers: + hosts: + backend: + backend2: + + # Reverse proxy servers + traefik_servers: + children: + traefik_servers_dmz: + traefik_servers_backend: + + # DMZ reverse proxy (public-facing, file provider mode) + traefik_servers_dmz: + hosts: + dmz: + + # Backend reverse proxy (docker provider mode) + traefik_servers_backend: + hosts: + backend: + backend2: + + # Application servers + httpbin_servers: + hosts: + backend: + backend2: + + keycloak_servers: + hosts: + backend: + + authentik_servers: + hosts: + backend: + + garage_servers: + hosts: + backend: + + nextcloud_servers: + hosts: + backend: \ No newline at end of file