- Git access to
https://github.com/bauer-group/IAC-Ansible.git - SSH access to target servers (root or sudo)
curl -fsSL https://raw.githubusercontent.com/bauer-group/IAC-Ansible/main/scripts/install.sh | bashcurl -fsSL https://raw.githubusercontent.com/bauer-group/IAC-Ansible/main/scripts/install.sh | \
BRANCH=main SCHEDULE="*-*-* 02:00:00" bashansible-pull looks itself up in the inventory via the system's FQDN. On a
fresh provider image the hostname is usually ubuntu or localhost and the
match fails, so host_vars/<name>.yml is never loaded. Pass IAC_HOSTNAME to
let the installer set the hostname (via hostnamectl, /etc/hosts and
preserve_hostname: true in /etc/cloud/cloud.cfg) before the first pull:
curl -fsSL https://raw.githubusercontent.com/bauer-group/IAC-Ansible/main/scripts/install.sh | \
IAC_HOSTNAME=0047-20.cloud.bauer-group.com bashCombinable with the other variables:
curl -fsSL https://raw.githubusercontent.com/bauer-group/IAC-Ansible/main/scripts/install.sh | \
IAC_HOSTNAME=0047-20.cloud.bauer-group.com BRANCH=main bashThe step is idempotent — running the installer again with the same
IAC_HOSTNAME value is a no-op.
Add to your cloud-init user-data:
#cloud-config
runcmd:
- curl -fsSL https://raw.githubusercontent.com/bauer-group/IAC-Ansible/main/scripts/install.sh | bashEdit inventory/production/hosts.yml:
auto_update:
hosts:
your-new-server.example.com:
ansible_host: your-new-server.example.com
platform: ubuntu_2404
labels:
- production
- webCommit and push. The server will pick up the changes on its next pull cycle.
make setupmake deploymake deploy LIMIT=0046-20.cloud.bauer-group.commake updatemake checkAll configuration is centralized in:
| What | Where |
|---|---|
| Global settings | inventory/production/group_vars/all/main.yml |
| Update schedule & behavior | inventory/production/group_vars/all/update_settings.yml |
| Per-host overrides | inventory/production/host_vars/<hostname>.yml |
After changing, commit and push. Servers will auto-apply on next pull.
make push LIMIT="0046-20.cloud.bauer-group.com"