Compare commits

..

3 Commits

4 changed files with 28 additions and 2 deletions

View File

@ -2,3 +2,5 @@
Ansible configs for the Skylab Homelab
Main entrypoint is through the `ansible` script in this repository. The script sets up basic
environment variables to avoid conflicts with other environments and sets the inventory.

8
ansible Executable file
View File

@ -0,0 +1,8 @@
#!/usr/bin/env bash
ANSIBLE_CONFIG=''
ANSIBLE_FILTER_PLUGINS=''
ANSIBLE_LIBRARY=''
ANSIBLE_INVENTORY=$(pwd)/inventory.yaml
"ansible-$1" ${@:2}

View File

@ -2,7 +2,7 @@
host_key_checking = false
[ssh_connection]
ssh_args = "-C -o ControlMaster=auto -o ControlPersist=60s -o ForwardAgent=yes"
ssh_args = "-o ControlMaster=auto -o ControlPersist=60s -o ForwardAgent=yes"
[inventory]
enable_plugins = yaml
enable_plugins = ansible.builtin.yaml

16
inventory.yaml Normal file
View File

@ -0,0 +1,16 @@
---
all:
vars:
skylab_state_dir: /var/run/skylab
skylab_ansible_venv: "{{ skylab_state_dir }}/ansible-runtime"
ansible_user: ansible
ansible_python_interpreter: "{{ skylab_ansible_venv }}/bin/python"
ansible_ssh_common_args: "-o ControlMaster=auto -o ControlPersist=60s -o ForwardAgent=yes"
en2:
vars:
skylab_location: DigitalOcean NYC1
hosts:
hubble:
ansible_host: en2a.enp.one
skylab_description: Cloud Web Server