Table of Contents
catboy.house is a server that I used to share with someone else, hosting various services and projects.
I took over the server and am now in the process of migrating the existing services to be defined by Ansible.
Later on, I'm planning to add more public services for everyone to use.
Instructions for setting up playbook execution and contribution. Most likely, you won't need this.
- Python
python -m pip install ansible
ansible-galaxy install -r requirements.yml
- Add the host
catboy-house
to your ssh config - Have your public ssh key added by someone with access.
Get the .vault_password
file from someone and put it in the project root.
(become is Ansible's sudo)
Encrypt your server linux account's password and store it in host_vars/catboy_house/become.yml
like this:
ansible-vault encrypt_string '<password>' --name ansible_become_pass > host_vars/catboy_house/become.yml
Running all Playbooks
./run.sh
Running tasks with specific tags
./run.sh --tags <tags>
Running single Playbooks
ansible-playbook -i inventory.yml <playbook>
Linting
ansible-lint
Encrypting variables
ansible-vault encrypt_string <string> --name <var-name>
Tasks are be named with what they do, in third-person singular, e.g. "🫖 Makes a tea".
Task names are prefixed with specific emojis to make the output and nature of the task more scannable.
- 🚀 are application/container launches.
- 📂 are folder creations.
- ⬆️ for file/template copying.
- 📦 are package installations.
- 👤 are user and group creations.
- 💾 are fact sets.
- ✅ are checks.
- ⛔ are fail states.
You may re-use files and roles from this repository for you own projects as long as you comply to the terms of the GNU Affero General Public License version 3.0.