diff options
author | Emil Renner Berthing <esmil@labitat.dk> | 2018-09-26 13:04:38 +0200 |
---|---|---|
committer | Emil Renner Berthing <esmil@labitat.dk> | 2018-09-26 13:04:38 +0200 |
commit | 8e5916ac7ef161432abedd8c6948a8db2b5c8169 (patch) | |
tree | e56158101666b2ec65f77222cd839b077c36b586 /roles | |
parent | 72e69659fe0a51bf2e61cebdb0b3c66ee9e564ba (diff) | |
download | labitat-ansible-8e5916ac7ef161432abedd8c6948a8db2b5c8169.tar.gz labitat-ansible-8e5916ac7ef161432abedd8c6948a8db2b5c8169.tar.xz labitat-ansible-8e5916ac7ef161432abedd8c6948a8db2b5c8169.zip |
space_server: kernel: better cmdline template
Diffstat (limited to 'roles')
-rw-r--r-- | roles/space_server/templates/cmdline.j2 | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/roles/space_server/templates/cmdline.j2 b/roles/space_server/templates/cmdline.j2 index 36b1e15..d3bd2e7 100644 --- a/roles/space_server/templates/cmdline.j2 +++ b/roles/space_server/templates/cmdline.j2 @@ -1,5 +1,8 @@ -{% if ansible_distribution_release == 'Rawhide' %} -console=ttyS0,115200n8 ro root={{ root.device }} rootfstype=btrfs ro rootflags={{ root.options|regex_replace('noatime,','') }},subvol=/rawhide rootwait audit=0 +{% if 'subvolume' in root %} +{% set subvol = root.subvolume %} +{% elif ansible_distribution_release == 'Rawhide' %} +{% set subvol = '/rawhide' %} {% else %} -console=ttyS0,115200n8 ro root={{ root.device }} rootfstype=btrfs ro rootflags={{ root.options|regex_replace('noatime,','') }},subvol=/{{ ansible_distribution.lower() }}{{ ansible_distribution_version }} rootwait audit=0 +{% set subvol = '/%s%s' % (ansible_distribution.lower(), ansible_distribution_version) %} {% endif %} +console=ttyS0,115200n8 ro root={{ root.device }} rootfstype=btrfs ro rootflags={{ root.options|regex_replace('noatime,','') }},subvol={{ subvol }} rootwait audit=0 |