diff options
author | Christian Pointner <equinox@spreadspace.org> | 2020-07-03 02:01:24 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2020-07-03 02:01:24 +0200 |
commit | 786d31170abb926496e2a8964157e474c2b32b2d (patch) | |
tree | 7aa6c6577e6bd582221909dc85c2bc364ff49ae4 /roles/cloud | |
parent | fix bar-variable warning (diff) | |
parent | use new preseed config in some hosts (diff) |
Merge branch 'topic/preseed-configurable-disk-layout'
Diffstat (limited to 'roles/cloud')
-rw-r--r-- | roles/cloud/install/templates/hetzner_installimage.conf.j2 | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/roles/cloud/install/templates/hetzner_installimage.conf.j2 b/roles/cloud/install/templates/hetzner_installimage.conf.j2 index 0881b110..ed22f286 100644 --- a/roles/cloud/install/templates/hetzner_installimage.conf.j2 +++ b/roles/cloud/install/templates/hetzner_installimage.conf.j2 @@ -1,15 +1,13 @@ HOSTNAME {{ host_name }}{% if host_domain %}.{{ host_domain }}{% endif %}{{ '' }} {% if cloud_provider == "hroot" %} -{% if install_cooked.disks.layout == "nvme_raid" %} -DRIVE1 /dev/nvme0n1 -DRIVE2 /dev/nvme1n1 +{% if install_cooked.disks.primary == "software-raid" %} +{% for raid_member in install_cooked.disks.raid.members %} +DRIVE{{ loop.index }} {{ raid_member }} +{% endfor %} SWRAID 1 -SWRAIDLEVEL 1 -{% elif install_cooked.disks.layout == "sata_raid" %} -DRIVE1 /dev/sda -DRIVE2 /dev/sdb -SWRAID 1 -SWRAIDLEVEL 1 +SWRAIDLEVEL {{ install_cooked.disks.raid.level }} +{% else %} +DRIVE1 {{ install_cooked.disks.primary }} {% endif %} {% elif cloud_provider == "hcloud" %} DRIVE1 /dev/sda |