diff --git a/group_vars/all.yml b/group_vars/all.yml index b76debe..373be09 100644 --- a/group_vars/all.yml +++ b/group_vars/all.yml @@ -52,4 +52,4 @@ instance_debootstrap: - name: default arch: amd64 suite: bookworm - extra_pkgs: "acpi-support-base,console-tools,udev,linux-image-amd64,sudo,vim,grub-pc,openssh-server" + extra_pkgs: "acpi-support-base,udev,linux-image-amd64,sudo,vim,grub-pc,openssh-server" diff --git a/inventory b/inventory index 47ba6f6..4823ea4 100644 --- a/inventory +++ b/inventory @@ -1,9 +1,11 @@ [nodes] 192.168.50.20 192.168.50.21 +192.168.50.22 [master] 192.168.50.20 [workers] 192.168.50.21 +192.168.50.22 diff --git a/roles/node/tasks/debootstrap.yml b/roles/node/tasks/debootstrap.yml new file mode 100644 index 0000000..e57f6c3 --- /dev/null +++ b/roles/node/tasks/debootstrap.yml @@ -0,0 +1,6 @@ +- name: Generate debootstrap configs + ansible.builtin.template: + src: etc-ganeti-instance-debootstrap-variants.j2 + dest: "/etc/ganeti/instance-debootstrap/variants/{{ item.name }}.conf" + mode: "0644" + loop: "{{ instance_debootstrap }}" diff --git a/roles/node/tasks/instance_debootstrap b/roles/node/tasks/instance_debootstrap new file mode 100644 index 0000000..e69de29 diff --git a/roles/node/tasks/main.yml b/roles/node/tasks/main.yml index d4e547c..82fb2d0 100644 --- a/roles/node/tasks/main.yml +++ b/roles/node/tasks/main.yml @@ -25,3 +25,7 @@ - name: Exchange keys ansible.builtin.include_tasks: file: keys.yml + +- name: Configure debootstrap + ansible.builtin.include_tasks: + file: debootstrap.yml diff --git a/roles/node/templates/etc-ganeti-instance-debootstrap-variants.j2 b/roles/node/templates/etc-ganeti-instance-debootstrap-variants.j2 new file mode 100644 index 0000000..da9d79e --- /dev/null +++ b/roles/node/templates/etc-ganeti-instance-debootstrap-variants.j2 @@ -0,0 +1,3 @@ +ARCH={{ item.arch }} +SUITE={{ item.suite }} +EXTRA_PKGS="{{ item.extra_pkgs }}" \ No newline at end of file diff --git a/roles/zfs-extstorage/tasks/main.yml b/roles/zfs-extstorage/tasks/main.yml index 43f9239..93f51bd 100644 --- a/roles/zfs-extstorage/tasks/main.yml +++ b/roles/zfs-extstorage/tasks/main.yml @@ -33,9 +33,9 @@ creates: /var/log/ganeti/extstorage register: create_log_directory_result -- name: Create lvm wrappers - ansible.builtin.command: - cmd: /usr/share/ganeti/extstorage/zfs/install/3-lvm-wrappers.sh - chdir: /usr/share/ganeti/extstorage/zfs/install/ - register: lvm_wrappers_result - changed_when: lvm_wrappers_result.rc == 0 +# - name: Create lvm wrappers +# ansible.builtin.command: +# cmd: /usr/share/ganeti/extstorage/zfs/install/3-lvm-wrappers.sh +# chdir: /usr/share/ganeti/extstorage/zfs/install/ +# register: lvm_wrappers_result +# changed_when: lvm_wrappers_result.rc == 0