X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=automation%2Fansible%2FREADME.md;h=fac4b7ceeb94a704d458159f77582eb2e4e11d81;hb=4f6c1ba91db07c3c42f7f294f4e75ee61227d48a;hp=e51165015ea2ff88d8868b54979f6d8d7b51b684;hpb=83d6ed6cc5e6d5d712dba19800cf61063b04fe7f;p=lttng-ci.git diff --git a/automation/ansible/README.md b/automation/ansible/README.md index e511650..fac4b7c 100644 --- a/automation/ansible/README.md +++ b/automation/ansible/README.md @@ -1,7 +1,13 @@ +# Setup on Ubuntu + +``` +apt install ansible ansible-mitogen +``` + # Required collections ``` -ansible-galaxy collection install community.general +ansible-galaxy install -r roles/requirements.yml ``` # Privileged data @@ -24,3 +30,115 @@ bw sync -f ``` ansible-playbook -i hosts [-l SUBSET] site.yaml ``` + +# Bootstrapping hosts + +## Windows + +1. Configure either SSH or WinRM connection: see https://docs.ansible.com/ansible/latest/os_guide/windows_setup.html +2. For arm64 hosts: + * Install the necessary optional features (eg. OpenSSH, Hyper-V) since Windows RSAT isn't available on Arm64 yet + +## CI 'rootnode' + +1. Add an entry to the `vms` variable in the host vars for a libvirt host + * See the defaults and details in `roles/libvirt/vars/main.yml` and `roles/libvirt/tasks/main.yml` + * Make sure to set the `cdrom` key to the path of ISO for the installer +2. Run the playbook, eg. `ansible-playbook -i hosts -l cloud07.internal.efficios.com site.yml` + * The VM should be created and started +3. Once the VM is installed take a snapshot so that Jenkins may revert to the original state + +### Ubuntu auto-installer + +1. Note your IP address +2. Switch to the directory with the user-data files: `cd roles/libvirt/files` +3. Write out the instance-specific metadata, eg. + +``` +cat > meta-data <