summaryrefslogtreecommitdiff
path: root/roles/installer/debian
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2021-07-02 14:03:42 +0200
committerChristian Pointner <equinox@spreadspace.org>2021-07-02 14:03:42 +0200
commit26dc8b9c6247f96fc047ad9a6408fad8cf7814b8 (patch)
tree21dd5f1805f312c78677b47c28e42b7139065c32 /roles/installer/debian
parentws fix (diff)
harmonize variable names used by debian/preseed installer role
Diffstat (limited to 'roles/installer/debian')
-rw-r--r--roles/installer/debian/iso/tasks/main.yml4
-rw-r--r--roles/installer/debian/iso/templates/grub.cfg.j24
-rw-r--r--roles/installer/debian/preseed/defaults/main.yml40
-rw-r--r--roles/installer/debian/preseed/tasks/main.yml22
-rw-r--r--roles/installer/debian/preseed/templates/partman_config.j210
-rw-r--r--roles/installer/debian/preseed/templates/preseed_debian-bullseye.cfg.j230
-rw-r--r--roles/installer/debian/preseed/templates/preseed_debian-buster.cfg.j230
-rw-r--r--roles/installer/debian/preseed/templates/preseed_debian-jessie.cfg.j230
-rw-r--r--roles/installer/debian/preseed/templates/preseed_debian-stretch.cfg.j230
-rw-r--r--roles/installer/debian/preseed/templates/preseed_ubuntu-bionic.cfg.j238
-rw-r--r--roles/installer/debian/preseed/templates/preseed_ubuntu-focal.cfg.j238
-rw-r--r--roles/installer/debian/preseed/templates/preseed_ubuntu-xenial.cfg.j232
-rw-r--r--roles/installer/debian/usb/tasks/main.yml4
13 files changed, 156 insertions, 156 deletions
diff --git a/roles/installer/debian/iso/tasks/main.yml b/roles/installer/debian/iso/tasks/main.yml
index 04d913c3..cfbb9721 100644
--- a/roles/installer/debian/iso/tasks/main.yml
+++ b/roles/installer/debian/iso/tasks/main.yml
@@ -28,8 +28,8 @@
- name: generate host specific initial ramdisk
vars:
- preseed_initrd: "{{ tmpdir.path }}/initrd.gz"
- preseed_tmpdir: "{{ tmpdir.path }}"
+ debian_preseed_initrd: "{{ tmpdir.path }}/initrd.gz"
+ debian_preseed_tmpdir: "{{ tmpdir.path }}"
import_role:
name: installer/debian/preseed
diff --git a/roles/installer/debian/iso/templates/grub.cfg.j2 b/roles/installer/debian/iso/templates/grub.cfg.j2
index 12b8837b..e2f480fa 100644
--- a/roles/installer/debian/iso/templates/grub.cfg.j2
+++ b/roles/installer/debian/iso/templates/grub.cfg.j2
@@ -15,6 +15,6 @@ set timeout=10
set default=0
menuentry "automated installer for {{ inventory_hostname }}" {
- linux /linux --- auto {{ (install_cooked.kernel_cmdline | default([])) | join(' ') }}
- initrd /initrd.gz
+ linux /linux --- auto {{ (install_cooked.kernel_cmdline | default([])) | join(' ') }}
+ initrd /initrd.gz
}
diff --git a/roles/installer/debian/preseed/defaults/main.yml b/roles/installer/debian/preseed/defaults/main.yml
index a0646b3b..fd57ef57 100644
--- a/roles/installer/debian/preseed/defaults/main.yml
+++ b/roles/installer/debian/preseed/defaults/main.yml
@@ -1,35 +1,35 @@
---
-# preseed_initrd:
-# preseed_tmpdir:
+# debian_preseed_initrd:
+# debian_preseed_tmpdir:
-preseed_language: en
-preseed_country: US
-preseed_locales:
+debian_preseed_language: en
+debian_preseed_country: US
+debian_preseed_locales:
- en_US.UTF-8
-preseed_keyboard_layout: de
-preseed_keyboard_variant: nodeadkeys
+debian_preseed_keyboard_layout: de
+debian_preseed_keyboard_variant: nodeadkeys
-preseed_timezone: Europe/Vienna
+debian_preseed_timezone: Europe/Vienna
-# preseed_force_net_ifnames_policy: path
-preseed_no_netplan: no
+# debian_preseed_force_net_ifnames_policy: path
+debian_preseed_no_netplan: no
-# preseed_kernel_image:
-preseed_virtual_machine: no
-preseed_no_splash: yes
+# debian_preseed_kernel_image:
+debian_preseed_virtual_machine: no
+debian_preseed_no_splash: yes
-preseed_manual_partitioning: no
+debian_preseed_manual_partitioning: no
-preseed_efi_esp_size: 128M
-preseed_swraid_boot_size: 256M
+debian_preseed_efi_esp_size: 128M
+debian_preseed_swraid_boot_size: 256M
## not used, see templates/partman_config.j2
-preseed_system_lvm_reserve_default: 384M
+debian_preseed_system_lvm_reserve_default: 384M
-preseed_system_lvm_size_default: all
-preseed_system_lvm_volumes_default:
+debian_preseed_system_lvm_size_default: all
+debian_preseed_system_lvm_volumes_default:
- name: root
size: 2560M
filesystem: ext4
@@ -48,4 +48,4 @@ preseed_system_lvm_volumes_default:
- noexec
-preseed_install_tasks: []
+debian_preseed_install_tasks: []
diff --git a/roles/installer/debian/preseed/tasks/main.yml b/roles/installer/debian/preseed/tasks/main.yml
index 525ba848..e3ea660f 100644
--- a/roles/installer/debian/preseed/tasks/main.yml
+++ b/roles/installer/debian/preseed/tasks/main.yml
@@ -1,45 +1,45 @@
---
- name: Generate preseed file
template:
- src: "preseed_{{ preseed_template_name | default(install_distro + '-' + install_codename) }}.cfg.j2"
- dest: "{{ preseed_tmpdir }}/preseed.cfg"
+ src: "preseed_{{ debian_preseed_template_name | default(install_distro + '-' + install_codename) }}.cfg.j2"
+ dest: "{{ debian_preseed_tmpdir }}/preseed.cfg"
- name: Generate partmam early-command script
- when: not preseed_manual_partitioning
+ when: not debian_preseed_manual_partitioning
template:
src: "partman_early-command.sh.j2"
- dest: "{{ preseed_tmpdir }}/partman_early-command.sh"
+ dest: "{{ debian_preseed_tmpdir }}/partman_early-command.sh"
mode: 0755
- name: Generate authorized_keys file
authorized_key:
user: root
manage_dir: no
- path: "{{ preseed_tmpdir }}/authorized_keys"
+ path: "{{ debian_preseed_tmpdir }}/authorized_keys"
key: "{{ ssh_keys_root | join('\n') }}"
- name: force net interface name policy
- when: preseed_force_net_ifnames_policy is defined
+ when: debian_preseed_force_net_ifnames_policy is defined
block:
- name: prepare directories to force network interface name policy
file:
- path: "{{ preseed_tmpdir }}/etc/systemd/network"
+ path: "{{ debian_preseed_tmpdir }}/etc/systemd/network"
state: directory
- name: install link unit to force network interface name policy
copy:
- dest: "{{ preseed_tmpdir }}/etc/systemd/network/90-namepolicy.link"
+ dest: "{{ debian_preseed_tmpdir }}/etc/systemd/network/90-namepolicy.link"
content: |
[Match]
OriginalName=*
[Link]
- NamePolicy={{ preseed_force_net_ifnames_policy }}
+ NamePolicy={{ debian_preseed_force_net_ifnames_policy }}
- name: Inject files into initramfs
- shell: cpio -H newc -o | gzip -9 >> '{{ preseed_initrd }}'
+ shell: cpio -H newc -o | gzip -9 >> '{{ debian_preseed_initrd }}'
args:
- chdir: "{{ preseed_tmpdir }}"
+ chdir: "{{ debian_preseed_tmpdir }}"
stdin: |
preseed.cfg
partman_early-command.sh
diff --git a/roles/installer/debian/preseed/templates/partman_config.j2 b/roles/installer/debian/preseed/templates/partman_config.j2
index 39003864..77bc0f8b 100644
--- a/roles/installer/debian/preseed/templates/partman_config.j2
+++ b/roles/installer/debian/preseed/templates/partman_config.j2
@@ -32,10 +32,10 @@ d-i partman-basicfilesystems/choose_label string msdos
d-i partman-basicfilesystems/default_label string msdos
{% endif %}
-{% set system_lvm_size = install_cooked.system_lvm.size | default(preseed_system_lvm_size_default) %}
-{% set system_lvm_volumes = install_cooked.system_lvm.volumes | default(preseed_system_lvm_volumes_default) %}
+{% set system_lvm_size = install_cooked.system_lvm.size | default(debian_preseed_system_lvm_size_default) %}
+{% set system_lvm_volumes = install_cooked.system_lvm.volumes | default(debian_preseed_system_lvm_volumes_default) %}
{# on small disks this probably triggers: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=896826 ... #}
-{# set system_lvm_reserve = install_cooked.system_lvm.reserve | default(preseed_system_lvm_reserve_default) #}
+{# set system_lvm_reserve = install_cooked.system_lvm.reserve | default(debian_preseed_system_lvm_reserve_default) #}
{# set system_lvm_pv_size_min_mb = (((system_lvm_volumes | map(attribute='size') | map('human_to_bytes') | sum) / (1024*1024)) | int) + (((system_lvm_reserve | human_to_bytes) / (1024*1024)) | int) #}
{# ... so let's go for a 1 MB minimum. #}
{% set system_lvm_pv_size_min_mb = 1 %}
@@ -48,14 +48,14 @@ d-i partman-auto/method string lvm
d-i partman-auto/expert_recipe string \
ansible :: \
{% if (install_cooked.efi | default(false)) %}
-{% set efi_esp_size_mb = ((preseed_efi_esp_size | human_to_bytes) / (1024*1024)) | int %}
+{% set efi_esp_size_mb = ((debian_preseed_efi_esp_size | human_to_bytes) / (1024*1024)) | int %}
{{ efi_esp_size_mb }} {{ efi_esp_size_mb }} {{ efi_esp_size_mb }} fat16 \
$primary{ } $bootable{ } \
method{ efi } format{ } \
. \
{% endif %}
{% if install_cooked.disks.primary == "software-raid" %}
-{% set swraid_boot_size_mb = ((preseed_swraid_boot_size | human_to_bytes) / (1024*1024)) | int %}
+{% set swraid_boot_size_mb = ((debian_preseed_swraid_boot_size | human_to_bytes) / (1024*1024)) | int %}
{{ swraid_boot_size_mb }} {{ swraid_boot_size_mb }} {{ swraid_boot_size_mb }} raid \
$lvmignore{ } $primary{ } $bootable{ } \
method{ raid } \
diff --git a/roles/installer/debian/preseed/templates/preseed_debian-bullseye.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_debian-bullseye.cfg.j2
index 3b240961..fa3304f4 100644
--- a/roles/installer/debian/preseed/templates/preseed_debian-bullseye.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_debian-bullseye.cfg.j2
@@ -2,15 +2,15 @@
# spreadspace preseed file for Debian bullseye based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
-d-i keyboard-configuration/xkb-keymap select {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/xkb-keymap select {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
@@ -47,24 +47,24 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
{% endif %}
d-i base-installer/install-recommends boolean false
d-i apt-setup/security_host string {{ apt_repo_providers[apt_repo_provider].debian_security.host }}
d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].debian_security.path }}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
@@ -76,13 +76,13 @@ d-i preseed/late_command string \
lvremove -f {{ host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Match]' > /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo 'OriginalName=*' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '[Link]' >> /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_debian-buster.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_debian-buster.cfg.j2
index 41e9d5ba..23fe064d 100644
--- a/roles/installer/debian/preseed/templates/preseed_debian-buster.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_debian-buster.cfg.j2
@@ -2,15 +2,15 @@
# spreadspace preseed file for Debian buster based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
-d-i keyboard-configuration/xkb-keymap select {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/xkb-keymap select {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
@@ -47,24 +47,24 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
{% endif %}
d-i base-installer/install-recommends boolean false
d-i apt-setup/security_host string {{ apt_repo_providers[apt_repo_provider].debian_security.host }}
d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].debian_security.path }}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
@@ -76,13 +76,13 @@ d-i preseed/late_command string \
lvremove -f {{ host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Match]' > /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo 'OriginalName=*' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '[Link]' >> /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_debian-jessie.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_debian-jessie.cfg.j2
index 1a3d6fd0..46a8be9a 100644
--- a/roles/installer/debian/preseed/templates/preseed_debian-jessie.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_debian-jessie.cfg.j2
@@ -2,15 +2,15 @@
# spreadspace preseed file for Debian jessie based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
-d-i keyboard-configuration/xkb-keymap select {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/xkb-keymap select {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
@@ -47,24 +47,24 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
{% endif %}
d-i base-installer/install-recommends boolean false
d-i apt-setup/security_host string
#d-i apt-setup/security_host string
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
@@ -76,10 +76,10 @@ d-i preseed/late_command string \
lvremove -f {{ host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Link]' > /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_debian-stretch.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_debian-stretch.cfg.j2
index f5227e54..172f1879 100644
--- a/roles/installer/debian/preseed/templates/preseed_debian-stretch.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_debian-stretch.cfg.j2
@@ -2,15 +2,15 @@
# spreadspace preseed file for Debian stretch based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
-d-i keyboard-configuration/xkb-keymap select {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/xkb-keymap select {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
@@ -47,24 +47,24 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
{% endif %}
d-i base-installer/install-recommends boolean false
d-i apt-setup/security_host string {{ apt_repo_providers[apt_repo_provider].debian_security.host }}
d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].debian_security.path }}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
@@ -76,10 +76,10 @@ d-i preseed/late_command string \
lvremove -f {{ host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Link]' > /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_ubuntu-bionic.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_ubuntu-bionic.cfg.j2
index a987a6c2..5768ad9c 100644
--- a/roles/installer/debian/preseed/templates/preseed_ubuntu-bionic.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_ubuntu-bionic.cfg.j2
@@ -2,20 +2,20 @@
# spreadspace preseed file for Ubuntu bionic based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
d-i localechooser/translation/warn-light boolean true
d-i console-setup/ask_detect boolean false
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
-{% if preseed_no_netplan %}
+{% if debian_preseed_no_netplan %}
d-i netcfg/do_not_use_netplan boolean true
{% endif %}
d-i netcfg/choose_interface select {{ install_interface | default(network_cooked.primary.name) }}
@@ -52,21 +52,21 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
-{% elif preseed_virtual_machine %}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
+{% elif debian_preseed_virtual_machine %}
d-i base-installer/kernel/image string linux-virtual
{% endif %}
-{% if preseed_no_splash %}
+{% if debian_preseed_no_splash %}
d-i debian-installer/splash boolean false
d-i debian-installer/add-kernel-opts string nosplash
{% endif %}
@@ -78,8 +78,8 @@ d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].ubun
d-i apt-setup/multiarch string amd64
{% endif %}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
-d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt{% if preseed_no_netplan %} ifupdown{% endif %}{{ '' }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
+d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt{% if debian_preseed_no_netplan %} ifupdown{% endif %}{{ '' }}
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
d-i pkgsel/update-policy select none
@@ -92,14 +92,14 @@ d-i preseed/late_command string \
in-target bash -c "swapoff -a; sed -e '/^\/swapfile/d' -i /etc/fstab; rm -f /swapfile"; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "env SUDO_FORCE_REMOVE=yes apt-get purge -y -q ubuntu-minimal sudo ubuntu-advantage-tools"; \
-{% if preseed_no_netplan %}
+{% if debian_preseed_no_netplan %}
in-target bash -c "apt-get purge -y -q netplan.io && apt-get autoremove -y -q && rm -rf /etc/netplan"; \
{% endif %}
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Link]' > /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_ubuntu-focal.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_ubuntu-focal.cfg.j2
index f33098a3..25c5f13d 100644
--- a/roles/installer/debian/preseed/templates/preseed_ubuntu-focal.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_ubuntu-focal.cfg.j2
@@ -2,20 +2,20 @@
# spreadspace preseed file for Ubuntu focal based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
d-i localechooser/translation/warn-light boolean true
d-i console-setup/ask_detect boolean false
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
-{% if preseed_no_netplan %}
+{% if debian_preseed_no_netplan %}
d-i netcfg/do_not_use_netplan boolean true
{% endif %}
d-i netcfg/choose_interface select {{ install_interface | default(network_cooked.primary.name) }}
@@ -52,21 +52,21 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
-{% elif preseed_virtual_machine %}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
+{% elif debian_preseed_virtual_machine %}
d-i base-installer/kernel/image string linux-virtual
{% endif %}
-{% if preseed_no_splash %}
+{% if debian_preseed_no_splash %}
d-i debian-installer/splash boolean false
d-i debian-installer/add-kernel-opts string nosplash
{% endif %}
@@ -78,8 +78,8 @@ d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].ubun
d-i apt-setup/multiarch string amd64
{% endif %}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
-d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt{% if preseed_no_netplan %} ifupdown{% endif %}{{ '' }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
+d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt{% if debian_preseed_no_netplan %} ifupdown{% endif %}{{ '' }}
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
d-i pkgsel/update-policy select none
@@ -92,17 +92,17 @@ d-i preseed/late_command string \
in-target bash -c "swapoff -a; sed -e '/^\/swapfile/d' -i /etc/fstab; rm -f /swapfile"; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "env SUDO_FORCE_REMOVE=yes apt-get purge -y -q ubuntu-minimal sudo ubuntu-advantage-tools"; \
-{% if preseed_no_netplan %}
+{% if debian_preseed_no_netplan %}
in-target bash -c "apt-get purge -y -q netplan.io && apt-get autoremove -y -q && rm -rf /etc/netplan"; \
{% endif %}
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Match]' > /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo 'OriginalName=*' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "echo '[Link]' >> /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/preseed/templates/preseed_ubuntu-xenial.cfg.j2 b/roles/installer/debian/preseed/templates/preseed_ubuntu-xenial.cfg.j2
index ae4deeea..248afd67 100644
--- a/roles/installer/debian/preseed/templates/preseed_ubuntu-xenial.cfg.j2
+++ b/roles/installer/debian/preseed/templates/preseed_ubuntu-xenial.cfg.j2
@@ -2,16 +2,16 @@
# spreadspace preseed file for Ubuntu xenial based machines
#########################################################################
-d-i debian-installer/language string {{ preseed_language }}
-d-i debian-installer/country string {{ preseed_country }}
-d-i debian-installer/locale string {{ preseed_locales | first }}
-d-i localechooser/preferred-locale string {{ preseed_locales | first }}
-d-i localechooser/supported-locales multiselect {{ preseed_locales | join(', ') }}
+d-i debian-installer/language string {{ debian_preseed_language }}
+d-i debian-installer/country string {{ debian_preseed_country }}
+d-i debian-installer/locale string {{ debian_preseed_locales | first }}
+d-i localechooser/preferred-locale string {{ debian_preseed_locales | first }}
+d-i localechooser/supported-locales multiselect {{ debian_preseed_locales | join(', ') }}
d-i localechooser/translation/warn-light boolean true
d-i console-setup/ask_detect boolean false
-d-i keyboard-configuration/layoutcode string {{ preseed_keyboard_layout }}
-d-i keyboard-configuration/variantcode string {{ preseed_keyboard_variant }}
+d-i keyboard-configuration/layoutcode string {{ debian_preseed_keyboard_layout }}
+d-i keyboard-configuration/variantcode string {{ debian_preseed_keyboard_variant }}
d-i hw-detect/load_firmware boolean false
@@ -49,21 +49,21 @@ d-i passwd/root-password-again password this-very-very-secure-password-will-be-r
d-i clock-setup/utc boolean true
-d-i time/zone string {{ preseed_timezone }}
+d-i time/zone string {{ debian_preseed_timezone }}
d-i clock-setup/ntp boolean false
-{% if not preseed_manual_partitioning %}
+{% if not debian_preseed_manual_partitioning %}
{% include 'partman_config.j2' %}
{% endif %}
-{% if preseed_kernel_image is defined %}
-d-i base-installer/kernel/image string {{ preseed_kernel_image }}
-{% elif preseed_virtual_machine %}
+{% if debian_preseed_kernel_image is defined %}
+d-i base-installer/kernel/image string {{ debian_preseed_kernel_image }}
+{% elif debian_preseed_virtual_machine %}
d-i base-installer/kernel/image string linux-virtual
{% endif %}
-{% if preseed_no_splash %}
+{% if debian_preseed_no_splash %}
d-i debian-installer/splash boolean false
d-i debian-installer/add-kernel-opts string nosplash
{% endif %}
@@ -75,7 +75,7 @@ d-i apt-setup/security_path string {{ apt_repo_providers[apt_repo_provider].ubun
d-i apt-setup/multiarch string amd64
{% endif %}
-tasksel tasksel/first multiselect {{ preseed_install_tasks | join(', ') }}
+tasksel tasksel/first multiselect {{ debian_preseed_install_tasks | join(', ') }}
d-i pkgsel/include string openssh-server {{ python_basename }} {{ python_basename }}-apt
d-i pkgsel/upgrade select safe-upgrade
popularity-contest popularity-contest/participate boolean false
@@ -89,10 +89,10 @@ d-i preseed/late_command string \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "env SUDO_FORCE_REMOVE=yes apt-get purge -y -q ubuntu-minimal sudo ubuntu-advantage-tools"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
-{% if preseed_force_net_ifnames_policy is defined %}
+{% if debian_preseed_force_net_ifnames_policy is defined %}
mkdir -p /target/etc/systemd/network; \
in-target bash -c "echo '[Link]' > /etc/systemd/network/90-namepolicy.link"; \
- in-target bash -c "echo 'NamePolicy={{ preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
+ in-target bash -c "echo 'NamePolicy={{ debian_preseed_force_net_ifnames_policy }}' >> /etc/systemd/network/90-namepolicy.link"; \
in-target bash -c "update-initramfs -u"; \
{% endif %}
in-target bash -c "passwd -d root && passwd -l root"; \
diff --git a/roles/installer/debian/usb/tasks/main.yml b/roles/installer/debian/usb/tasks/main.yml
index 62bfced7..491cde3d 100644
--- a/roles/installer/debian/usb/tasks/main.yml
+++ b/roles/installer/debian/usb/tasks/main.yml
@@ -51,8 +51,8 @@
- name: generate host specific initial ramdisk
vars:
- preseed_initrd: "{{ usb_install_path }}/initrd.{{ inventory_hostname }}.gz"
- preseed_tmpdir: "{{ tmpdir.path }}"
+ debian_preseed_initrd: "{{ usb_install_path }}/initrd.{{ inventory_hostname }}.gz"
+ debian_preseed_tmpdir: "{{ tmpdir.path }}"
import_role:
name: installer/debian/preseed