A series of Ansible scripts to manage my infrastructure.
Go to file
Salt 427014f2ae Sanitize tag hostgroups in nagios with the tag- prefix
Stumbled across an issue where I can't have a Netbox tag that's just 'ansible'
2021-09-26 10:23:46 -05:00
.templates Fix template 2020-10-17 00:27:46 -05:00
contrib Move requirements.yml to root 2021-08-01 21:39:36 -05:00
handlers Move handlers to global handlers 2020-12-20 05:02:17 -06:00
inventory Add test DB for gulagbot on Linode 2021-09-26 08:03:37 -05:00
inventory-hard Add emergency disaster-recovery inventory 2021-09-01 19:29:02 -05:00
playbooks Sanitize tag hostgroups in nagios with the tag- prefix 2021-09-26 10:23:46 -05:00
roles Remove error suppression for desktop role 2021-09-24 21:08:34 -05:00
.ansible-lint Reconfigure lint 2021-09-24 21:11:03 -05:00
.gitignore Install Galaxy roles to their own directory so I don't have to maintain a long gitignore 2021-09-18 16:13:20 -05:00
.gitlab-ci.yml Switch to using our brand-spankin new ansible-env container 2021-09-24 21:19:30 -05:00
ansible.cfg Install Galaxy roles to their own directory so I don't have to maintain a long gitignore 2021-09-18 16:13:20 -05:00
pull.yml Create dedicated ansible-pull playbook with basic maintenance tasks, use it 2021-09-22 07:43:28 -05:00
README.md Polish up README 2021-09-24 21:59:12 -05:00
reboot-home.yml Reconfigure reboot-home.yml 2021-09-14 19:06:46 -05:00
reboot-prod.yml Polish up those reboot playbooks 2021-08-25 12:20:47 -05:00
requirements.yml Remove another deprecated role 2021-09-18 16:11:48 -05:00
site.yml Add playbook and Netbox tag to run the ansible role on a host 2021-09-24 13:03:21 -05:00

Salt's Ansible Repository

Useful for management across all of 9iron, thefuck, and desu.

Initialization

  • Clone
  • ansible-galaxy install -r requirements.yml

For quick bootstrapping of tools and libraries used in this repo, see rehashedsalt/ansible-env. I use that exact image for CI/CD.

Deployment

Adding a new server will require the following be fulfilled:

  • The server is accessible from the Ansible host;

  • The server has a user named ansible which:

    • Accepts the public key located in contrib/desu.pub; and

    • Has passwordless sudo capabilities as root

  • The server has been added to NetBox OR in inventory-hard

  • DNS records for the machine are set; and

  • The server is running Ubuntu 20.04 or greater

From there, running the playbook site.yml should get the machine up to snuff. To automate the host-local steps, use the script file contrib/bootstrap.sh.

Zerotier

A lot of my home-network side of things is connected together via ZeroTier; initial deployment/repairs may require specifying an ansible_host for the inventory item in question to connect to it locally. Subsequent plays will require connectivity to my home ZeroTier network.

Cloud-managed devices require no such workarounds.