refactor(vars): enforce nested system and hypervisor schema
This commit is contained in:
@@ -48,8 +48,8 @@
|
||||
chroot_command: >-
|
||||
{{
|
||||
'systemd-nspawn -D /mnt'
|
||||
if chroot_tool == 'systemd-nspawn'
|
||||
else chroot_tool ~ ' /mnt'
|
||||
if (system_cfg.features.chroot.tool | default('arch-chroot')) == 'systemd-nspawn'
|
||||
else (system_cfg.features.chroot.tool | default('arch-chroot')) ~ ' /mnt'
|
||||
}}
|
||||
changed_when: false
|
||||
|
||||
@@ -63,12 +63,12 @@
|
||||
|
||||
- name: Set SSH access
|
||||
when:
|
||||
- install_type == "virtual"
|
||||
- system_cfg.type == "virtual"
|
||||
- hypervisor_type != "vmware"
|
||||
ansible.builtin.set_fact:
|
||||
ansible_user: "{{ user_name }}"
|
||||
ansible_password: "{{ user_password }}"
|
||||
ansible_become_password: "{{ user_password }}"
|
||||
ansible_user: "{{ system_cfg.user.name }}"
|
||||
ansible_password: "{{ system_cfg.user.password }}"
|
||||
ansible_become_password: "{{ system_cfg.user.password }}"
|
||||
ansible_ssh_extra_args: "-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no"
|
||||
changed_when: false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user