summaryrefslogtreecommitdiff
path: root/roles
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2019-01-03 02:00:01 +0100
committerChristian Pointner <equinox@spreadspace.org>2019-01-03 02:00:07 +0100
commit88a9dd303ae7ee24e1fbbac41a0af5e1b2da5eb3 (patch)
tree9624fc346798c2b6adca4b85f80f99fa8617d3fd /roles
parentfix usb-install role to support UEFI, added very basic setup for media.elevat... (diff)
use host_name variable for lvm group name
Diffstat (limited to 'roles')
-rw-r--r--roles/preseed/templates/preseed_debian-stretch.cfg.j266
-rw-r--r--roles/preseed/templates/preseed_ubuntu-bionic.cfg.j266
-rw-r--r--roles/preseed/templates/preseed_ubuntu-xenial.cfg.j266
3 files changed, 99 insertions, 99 deletions
diff --git a/roles/preseed/templates/preseed_debian-stretch.cfg.j2 b/roles/preseed/templates/preseed_debian-stretch.cfg.j2
index 36d221a1..7237fa6d 100644
--- a/roles/preseed/templates/preseed_debian-stretch.cfg.j2
+++ b/roles/preseed/templates/preseed_debian-stretch.cfg.j2
@@ -18,8 +18,8 @@ d-i netcfg/get_gateway string {{ hostvars[hostname].network_cooked.primary.gatew
d-i netcfg/get_nameservers string {{ hostvars[hostname].network_cooked.nameservers | join(' ') }}
d-i netcfg/confirm_static boolean true
-d-i netcfg/hostname string {{ hostname }}
-d-i netcfg/get_hostname string {{ hostname }}
+d-i netcfg/hostname string {{ hostvars[hostname].host_name }}
+d-i netcfg/get_hostname string {{ hostvars[hostname].host_name }}
d-i netcfg/domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/get_domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/wireless_wep string
@@ -44,7 +44,7 @@ d-i clock-setup/ntp boolean false
d-i partman-auto/disk string /dev/{{ hostvars[hostname].install_cooked.disks.primary }}
d-i partman-auto/method string lvm
d-i partman-auto/purge_lvm_from_device boolean true
-d-i partman-auto-lvm/new_vg_name string {{ hostname }}
+d-i partman-auto-lvm/new_vg_name string {{ hostvars[hostname].host_name }}
d-i partman-auto-lvm/guided_size string max
d-i partman-lvm/device_remove_lvm boolean true
@@ -53,35 +53,35 @@ d-i partman-md/device_remove_md boolean true
d-i partman-lvm/confirm boolean true
d-i partman-lvm/confirm_nooverwrite boolean true
-d-i partman-auto/expert_recipe string \
- boot-root :: \
- 1000 10000 -1 ext4 \
- $defaultignore{ } $primary{ } $bootable{ } \
- method{ lvm } vg_name{ {{ hostname }} } \
- . \
- 2048 10000 2560 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ / } \
- . \
- 1024 11000 1280 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var } \
- . \
- 768 10000 768 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var/log } \
- options/nodev{ nodev } options/noatime{ noatime } \
- options/noexec{ noexec } \
- . \
- 16 20000 -1 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method( keep } lv_name{ dummy } \
+d-i partman-auto/expert_recipe string \
+ boot-root :: \
+ 1000 10000 -1 ext4 \
+ $defaultignore{ } $primary{ } $bootable{ } \
+ method{ lvm } vg_name{ {{ hostvars[hostname].host_name }} } \
+ . \
+ 2048 10000 2560 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ / } \
+ . \
+ 1024 11000 1280 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var } \
+ . \
+ 768 10000 768 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var/log } \
+ options/nodev{ nodev } options/noatime{ noatime } \
+ options/noexec{ noexec } \
+ . \
+ 16 20000 -1 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method( keep } lv_name{ dummy } \
.
d-i partman-auto-lvm/no_boot boolean true
@@ -108,7 +108,7 @@ d-i finish-install/reboot_in_progress note
d-i preseed/late_command string \
- lvremove -f {{ hostname }}/dummy; \
+ lvremove -f {{ hostvars[hostname].host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "passwd -d root && passwd -l root"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \
diff --git a/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2 b/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2
index 8c7093aa..b9263074 100644
--- a/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2
+++ b/roles/preseed/templates/preseed_ubuntu-bionic.cfg.j2
@@ -22,8 +22,8 @@ d-i netcfg/get_gateway string {{ hostvars[hostname].network_cooked.primary.gatew
d-i netcfg/get_nameservers string {{ hostvars[hostname].network_cooked.nameservers | join(' ') }}
d-i netcfg/confirm_static boolean true
-d-i netcfg/hostname string {{ hostname }}
-d-i netcfg/get_hostname string {{ hostname }}
+d-i netcfg/hostname string {{ hostvars[hostname].host_name }}
+d-i netcfg/get_hostname string {{ hostvars[hostname].host_name }}
d-i netcfg/domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/get_domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/wireless_wep string
@@ -49,7 +49,7 @@ d-i clock-setup/ntp boolean false
d-i partman-auto/disk string /dev/{{ hostvars[hostname].install_cooked.disks.primary }}
d-i partman-auto/method string lvm
d-i partman-auto/purge_lvm_from_device boolean true
-d-i partman-auto-lvm/new_vg_name string {{ hostname }}
+d-i partman-auto-lvm/new_vg_name string {{ hostvars[hostname].host_name }}
d-i partman-auto-lvm/guided_size string max
d-i partman-lvm/device_remove_lvm boolean true
@@ -58,35 +58,35 @@ d-i partman-md/device_remove_md boolean true
d-i partman-lvm/confirm boolean true
d-i partman-lvm/confirm_nooverwrite boolean true
-d-i partman-auto/expert_recipe string \
- boot-root :: \
- 1000 10000 -1 ext4 \
- $defaultignore{ } $primary{ } $bootable{ } \
- method{ lvm } vg_name{ {{ hostname }} } \
- . \
- 2048 10000 2560 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ / } \
- . \
- 1024 11000 1280 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var } \
- . \
- 768 10000 768 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var/log } \
- options/nodev{ nodev } options/noatime{ noatime } \
- options/noexec{ noexec } \
- . \
- 16 20000 -1 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method( keep } lv_name{ dummy } \
+d-i partman-auto/expert_recipe string \
+ boot-root :: \
+ 1000 10000 -1 ext4 \
+ $defaultignore{ } $primary{ } $bootable{ } \
+ method{ lvm } vg_name{ {{ hostvars[hostname].host_name }} } \
+ . \
+ 2048 10000 2560 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ / } \
+ . \
+ 1024 11000 1280 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var } \
+ . \
+ 768 10000 768 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var/log } \
+ options/nodev{ nodev } options/noatime{ noatime } \
+ options/noexec{ noexec } \
+ . \
+ 16 20000 -1 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method( keep } lv_name{ dummy } \
.
d-i partman-auto-lvm/no_boot boolean true
@@ -114,7 +114,7 @@ d-i finish-install/reboot_in_progress note
d-i preseed/late_command string \
- lvremove -f {{ hostname }}/dummy; \
+ lvremove -f {{ hostvars[hostname].host_name }}/dummy; \
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 "passwd -d root && passwd -l root"; \
diff --git a/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2 b/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2
index 1be16ff8..0b725c6f 100644
--- a/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2
+++ b/roles/preseed/templates/preseed_ubuntu-xenial.cfg.j2
@@ -22,8 +22,8 @@ d-i netcfg/get_gateway string {{ hostvars[hostname].network_cooked.primary.gatew
d-i netcfg/get_nameservers string {{ hostvars[hostname].network_cooked.nameservers | join(' ') }}
d-i netcfg/confirm_static boolean true
-d-i netcfg/hostname string {{ hostname }}
-d-i netcfg/get_hostname string {{ hostname }}
+d-i netcfg/hostname string {{ hostvars[hostname].host_name }}
+d-i netcfg/get_hostname string {{ hostvars[hostname].host_name }}
d-i netcfg/domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/get_domain string {{ hostvars[hostname].network_cooked.domain }}
d-i netcfg/wireless_wep string
@@ -49,7 +49,7 @@ d-i clock-setup/ntp boolean false
d-i partman-auto/disk string /dev/{{ hostvars[hostname].install_cooked.disks.primary }}
d-i partman-auto/method string lvm
d-i partman-auto/purge_lvm_from_device boolean true
-d-i partman-auto-lvm/new_vg_name string {{ hostname }}
+d-i partman-auto-lvm/new_vg_name string {{ hostvars[hostname].host_name }}
d-i partman-auto-lvm/guided_size string max
d-i partman-lvm/device_remove_lvm boolean true
@@ -58,35 +58,35 @@ d-i partman-md/device_remove_md boolean true
d-i partman-lvm/confirm boolean true
d-i partman-lvm/confirm_nooverwrite boolean true
-d-i partman-auto/expert_recipe string \
- boot-root :: \
- 1000 10000 -1 ext4 \
- $defaultignore{ } $primary{ } $bootable{ } \
- method{ lvm } vg_name{ {{ hostname }} } \
- . \
- 2048 10000 2560 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ / } \
- . \
- 1024 11000 1280 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var } \
- . \
- 768 10000 768 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method{ format } format{ } \
- use_filesystem{ } filesystem{ ext4 } \
- mountpoint{ /var/log } \
- options/nodev{ nodev } options/noatime{ noatime } \
- options/noexec{ noexec } \
- . \
- 16 20000 -1 ext4 \
- $lvmok{ } in_vg{ {{ hostname }} } \
- method( keep } lv_name{ dummy } \
+d-i partman-auto/expert_recipe string \
+ boot-root :: \
+ 1000 10000 -1 ext4 \
+ $defaultignore{ } $primary{ } $bootable{ } \
+ method{ lvm } vg_name{ {{ hostvars[hostname].host_name }} } \
+ . \
+ 2048 10000 2560 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ / } \
+ . \
+ 1024 11000 1280 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var } \
+ . \
+ 768 10000 768 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method{ format } format{ } \
+ use_filesystem{ } filesystem{ ext4 } \
+ mountpoint{ /var/log } \
+ options/nodev{ nodev } options/noatime{ noatime } \
+ options/noexec{ noexec } \
+ . \
+ 16 20000 -1 ext4 \
+ $lvmok{ } in_vg{ {{ hostvars[hostname].host_name }} } \
+ method( keep } lv_name{ dummy } \
.
d-i partman-auto-lvm/no_boot boolean true
@@ -114,7 +114,7 @@ d-i finish-install/reboot_in_progress note
d-i preseed/late_command string \
- lvremove -f {{ hostname }}/dummy; \
+ lvremove -f {{ hostvars[hostname].host_name }}/dummy; \
in-target bash -c "apt-get update -q && apt-get full-upgrade -y -q"; \
in-target bash -c "passwd -d root && passwd -l root"; \
in-target bash -c "sed -e 's/^allow-hotplug/auto/' -i /etc/network/interfaces"; \