Fix command module formating
This commit is contained in:
@@ -18,8 +18,7 @@
|
|||||||
changed_when: result.rc == 0
|
changed_when: result.rc == 0
|
||||||
register: result
|
register: result
|
||||||
with_items:
|
with_items:
|
||||||
- |
|
- debootstrap --include={{ role_packages[os].base | join(',') }} {{ 'bullseye' if os == 'debian11' else 'bookworm' }}
|
||||||
debootstrap --include={{ role_packages[os].base | join(',') }} {{ 'bullseye' if os == 'debian11' else 'bookworm' }} \
|
|
||||||
/mnt http://deb.debian.org/debian/
|
/mnt http://deb.debian.org/debian/
|
||||||
- arch-chroot /mnt apt install -y {{ role_packages[os].extra | join(' ') }}
|
- arch-chroot /mnt apt install -y {{ role_packages[os].extra | join(' ') }}
|
||||||
- arch-chroot /mnt apt remove -y libcups2 libavahi-common3 libavahi-common-data
|
- arch-chroot /mnt apt remove -y libcups2 libavahi-common3 libavahi-common-data
|
||||||
@@ -30,8 +29,7 @@
|
|||||||
changed_when: result.rc == 0
|
changed_when: result.rc == 0
|
||||||
register: result
|
register: result
|
||||||
with_items:
|
with_items:
|
||||||
- |
|
- debootstrap --include={{ role_packages[os].base | join(',') }} {{ 'mantic' if os == 'ubuntu' else 'jammy' }}
|
||||||
debootstrap --include={{ role_packages[os].base | join(',') }} {{ 'mantic' if os == 'ubuntu' else 'jammy' }} \
|
|
||||||
/mnt http://archive.ubuntu.com/ubuntu/
|
/mnt http://archive.ubuntu.com/ubuntu/
|
||||||
- ln -sf /run/systemd/resolve/resolv.conf /mnt/etc/resolv.conf
|
- ln -sf /run/systemd/resolve/resolv.conf /mnt/etc/resolv.conf
|
||||||
- arch-chroot /mnt sed -i '1s|$| universe|' /etc/apt/sources.list
|
- arch-chroot /mnt sed -i '1s|$| universe|' /etc/apt/sources.list
|
||||||
@@ -54,8 +52,7 @@
|
|||||||
changed_when: result.rc == 0
|
changed_when: result.rc == 0
|
||||||
register: result
|
register: result
|
||||||
with_items:
|
with_items:
|
||||||
- |
|
- dnf --releasever=40 --best --repo=fedora --repo=fedora-updates
|
||||||
dnf --releasever=40 --best --repo=fedora --repo=fedora-updates \
|
|
||||||
--installroot=/mnt --setopt=install_weak_deps=False groupinstall -y critical-path-base core
|
--installroot=/mnt --setopt=install_weak_deps=False groupinstall -y critical-path-base core
|
||||||
- ln -sf /run/systemd/resolve/resolv.conf /mnt/etc/resolv.conf
|
- ln -sf /run/systemd/resolve/resolv.conf /mnt/etc/resolv.conf
|
||||||
- arch-chroot /mnt dnf --releasever=40 --setopt=install_weak_deps=False install -y {{ role_packages.fedora | join(' ') }}
|
- arch-chroot /mnt dnf --releasever=40 --setopt=install_weak_deps=False install -y {{ role_packages.fedora | join(' ') }}
|
||||||
|
|||||||
@@ -122,7 +122,7 @@
|
|||||||
- { path: /mnt/etc/crontab, mode: "0600" }
|
- { path: /mnt/etc/crontab, mode: "0600" }
|
||||||
- { path: /mnt/etc/logrotate.conf, mode: "0644" }
|
- { path: /mnt/etc/logrotate.conf, mode: "0644" }
|
||||||
- { path: /mnt/usr/sbin/pppd, mode: "754" }
|
- { path: /mnt/usr/sbin/pppd, mode: "754" }
|
||||||
- { path: '/mnt/usr/bin/{{ "fusermount3" if os in ["archlinux", "debian12", "fedora"] else "fusermount" }}', mode: "755" }
|
- { path: '/mnt/usr/bin/{{ "fusermount3" if os in ["archlinux", "debian12", "fedora", "rocky", "almalinux"] else "fusermount" }}', mode: "755" }
|
||||||
- { path: '/mnt/usr/bin/{{ "write.ul" if os == "debian11" else "write" }}', mode: "755" }
|
- { path: '/mnt/usr/bin/{{ "write.ul" if os == "debian11" else "write" }}', mode: "755" }
|
||||||
|
|
||||||
- name: Adjust SSHD config
|
- name: Adjust SSHD config
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
|
|
||||||
- name: Create cloud-init disk
|
- name: Create cloud-init disk
|
||||||
delegate_to: localhost
|
delegate_to: localhost
|
||||||
ansible.builtin.shell: |
|
ansible.builtin.shell: >
|
||||||
cloud-localds {{ vm_path | default('/var/lib/libvirt/images/') }}\
|
cloud-localds {{ vm_path | default('/var/lib/libvirt/images/') }}\
|
||||||
{{ hostname }}-cloudinit.iso /tmp/cloud-user-data-{{ hostname }}.yml \
|
{{ hostname }}-cloudinit.iso /tmp/cloud-user-data-{{ hostname }}.yml \
|
||||||
-N /tmp/cloud-network-config-{{ hostname }}.yml
|
-N /tmp/cloud-network-config-{{ hostname }}.yml
|
||||||
|
|||||||
Reference in New Issue
Block a user