From 8177287664ddbf1c690a8a9b3d721c2dbb87d339 Mon Sep 17 00:00:00 2001 From: Edwin Zhang Date: Sat, 16 Jul 2022 23:04:22 -0400 Subject: [PATCH] Switch to yaml inventory --- ansible.cfg | 2 +- hosts | 106 ------------------------------------------ inventory.yaml | 124 +++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 125 insertions(+), 107 deletions(-) delete mode 100644 hosts create mode 100644 inventory.yaml diff --git a/ansible.cfg b/ansible.cfg index 930e582..dd435ac 100644 --- a/ansible.cfg +++ b/ansible.cfg @@ -6,7 +6,7 @@ nocows = 1 timeout = 60 # Inventory -inventory = hosts +inventory = inventory.yaml # Logging log_path = ansible.log diff --git a/hosts b/hosts deleted file mode 100644 index 5b9c28b..0000000 --- a/hosts +++ /dev/null @@ -1,106 +0,0 @@ -[new-office] - -[bare-metal:children] -general-use-bare-metal -syscom-bare-metal -mirror -audio-sink - -[containers:children] -general-use-containers -syscom-containers - -[general-use:children] -general-use-bare-metal -general-use-containers - -[general-use-bare-metal] -corn-syrup.csclub.uwaterloo.ca -hfcs.csclub.uwaterloo.ca -sucrose.csclub.uwaterloo.ca -taurine.csclub.uwaterloo.ca - -[general-use-containers] -caffeine.csclub.uwaterloo.ca - -[general-use-containers:children] -webnodes - -[webnodes] -caffeine-00.csclub.uwaterloo.ca -caffeine-01.csclub.uwaterloo.ca - -[office] -bit-shifter.csclub.uwaterloo.ca -gwem.csclub.uwaterloo.ca -maltodextrin.csclub.uwaterloo.ca -natural-flavours.csclub.uwaterloo.ca -strombola.csclub.uwaterloo.ca - -[syscom:children] -syscom-bare-metal -syscom-containers -cloud - -[syscom-bare-metal] -aspartame.csclub.uwaterloo.ca -dextrose.csclub.uwaterloo.ca -cobalamin.csclub.uwaterloo.ca -glomag.csclub.uwaterloo.ca -potassium-benzoate.csclub.uwaterloo.ca -sodium-benzoate.csclub.uwaterloo.ca -yerba-mate.csclub.uwaterloo.ca -guayusa.csclub.uwaterloo.ca -coffee.csclub.uwaterloo.ca - -[cloud] -db1.cloud.csclub.uwaterloo.ca -controller1.cloud.csclub.uwaterloo.ca -network1.cloud.csclub.uwaterloo.ca -block1.cloud.csclub.uwaterloo.ca -object1.cloud.csclub.uwaterloo.ca -web1.cloud.csclub.uwaterloo.ca -router1.cloud.csclub.uwaterloo.ca -ginkgo.csclub.uwaterloo.ca - -[syscom-containers] -auth1.csclub.uwaterloo.ca -auth2.csclub.uwaterloo.ca -mail.csclub.uwaterloo.ca -munin.csclub.uwaterloo.ca -rt.csclub.uwaterloo.ca -netbox.csclub.uwaterloo.ca -logstash.csclub.uwaterloo.ca -dns1.csclub.uwaterloo.ca -dns2.csclub.uwaterloo.ca -cifs.csclub.uwaterloo.ca -mattermost.csclub.uwaterloo.ca -shibboleth.csclub.uwaterloo.ca -test-ipv6.csclub.uwaterloo.ca -etcd-mc.csclub.uwaterloo.ca -etcd-dc.csclub.uwaterloo.ca -etcd-phy.csclub.uwaterloo.ca -prometheus.csclub.uwaterloo.ca - -[syscom-containers:children] -load-balancers - -[audio-sink] -nullsleep.csclub.uwaterloo.ca - -[mirror] -potassium-benzoate.csclub.uwaterloo.ca - -[load-balancers] -load-balancer-01.csclub.uwaterloo.ca lb_priority=110 -load-balancer-02.csclub.uwaterloo.ca lb_priority=100 - -[cloud-csc-club-managed:children] -club-iie -club-uwarc - -[club-iie] -wiki.iie.csclub.cloud - -[club-uwarc] -wiki.uwarc.csclub.cloud diff --git a/inventory.yaml b/inventory.yaml new file mode 100644 index 0000000..a874cfd --- /dev/null +++ b/inventory.yaml @@ -0,0 +1,124 @@ +new_office: + hosts: + +bare_metal: + children: + general_use_bare_metal: + syscom_bare_metal: + mirror: + audio_sink: + +containers: + children: + general_use_containers: + syscom_containers: + +general_use: + children: + general_use_bare_metal: + general_use_containers: + +general_use_bare_metal: + hosts: + corn-syrup.csclub.uwaterloo.ca: + hfcs.csclub.uwaterloo.ca: + sucrose.csclub.uwaterloo.ca: + taurine.csclub.uwaterloo.ca: + +general_use_containers: + hosts: + caffeine.csclub.uwaterloo.ca: + children: + webnodes: + +webnodes: + hosts: + caffeine-00.csclub.uwaterloo.ca: + caffeine-01.csclub.uwaterloo.ca: + +office: + hosts: + bit-shifter.csclub.uwaterloo.ca: + gwem.csclub.uwaterloo.ca: + maltodextrin.csclub.uwaterloo.ca: + natural-flavours.csclub.uwaterloo.ca: + strombola.csclub.uwaterloo.ca: + +syscom: + children: + syscom-bare-metal: + syscom-containers: + cloud: + +syscom-bare-metal: + hosts: + aspartame.csclub.uwaterloo.ca: + dextrose.csclub.uwaterloo.ca: + cobalamin.csclub.uwaterloo.ca: + glomag.csclub.uwaterloo.ca: + potassium-benzoate.csclub.uwaterloo.ca: + sodium-benzoate.csclub.uwaterloo.ca: + yerba-mate.csclub.uwaterloo.ca: + guayusa.csclub.uwaterloo.ca: + coffee.csclub.uwaterloo.ca: + +cloud: + hosts: + db1.cloud.csclub.uwaterloo.ca: + controller1.cloud.csclub.uwaterloo.ca: + network1.cloud.csclub.uwaterloo.ca: + block1.cloud.csclub.uwaterloo.ca: + object1.cloud.csclub.uwaterloo.ca: + web1.cloud.csclub.uwaterloo.ca: + router1.cloud.csclub.uwaterloo.ca: + ginkgo.csclub.uwaterloo.ca: + +syscom-containers: + hosts: + auth1.csclub.uwaterloo.ca: + auth2.csclub.uwaterloo.ca: + mail.csclub.uwaterloo.ca: + munin.csclub.uwaterloo.ca: + rt.csclub.uwaterloo.ca: + netbox.csclub.uwaterloo.ca: + logstash.csclub.uwaterloo.ca: + dns1.csclub.uwaterloo.ca: + dns2.csclub.uwaterloo.ca: + cifs.csclub.uwaterloo.ca: + mattermost.csclub.uwaterloo.ca: + shibboleth.csclub.uwaterloo.ca: + test-ipv6.csclub.uwaterloo.ca: + etcd-mc.csclub.uwaterloo.ca: + etcd-dc.csclub.uwaterloo.ca: + etcd-phy.csclub.uwaterloo.ca: + prometheus.csclub.uwaterloo.ca: + children: + load-balancers: + +audio-sink: + hosts: + nullsleep.csclub.uwaterloo.ca: + +mirror: + hosts: + potassium-benzoate.csclub.uwaterloo.ca: + +load-balancers: + hosts: + load-balancer-01.csclub.uwaterloo.ca: + lb_priority: 110 + load-balancer-02.csclub.uwaterloo.ca: + lb_priority: 100 + +cloud-csc-club-managed: + children: + club-iie: + club-uwarc: + +club-iie: + hosts: + wiki.iie.csclub.cloud + +club-uwarc: + hosts: + wiki.uwarc.csclub.cloud