From c588acfc1306bf036a0923b6af0211a99ac19ce0 Mon Sep 17 00:00:00 2001 From: Markus Katharina Brechtel Date: Thu, 12 Oct 2017 19:12:09 +0000 Subject: [PATCH] make the end point of last partition configurable --- defaults/main.yml | 1 + templates/partitions.json.j2 | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) create mode 100644 defaults/main.yml diff --git a/defaults/main.yml b/defaults/main.yml new file mode 100644 index 0000000..dbb4865 --- /dev/null +++ b/defaults/main.yml @@ -0,0 +1 @@ +partitioning_profile_last_partition_end: -1MiB diff --git a/templates/partitions.json.j2 b/templates/partitions.json.j2 index 36614c3..64d4c73 100644 --- a/templates/partitions.json.j2 +++ b/templates/partitions.json.j2 @@ -22,7 +22,7 @@ { "part_type": "primary", "start": "6GiB", - "end": "-1MiB" + "end": "{{ partitioning_profile_last_partition_end }}" } {% endif %} {% if partitioning_profile == "efi-dmcrypt-lvm" %} @@ -52,7 +52,7 @@ "name": "{{partition_name_prefix}}-crypt", "typecode": "8300", "start": "6GiB", - "end": "-1MiB" + "end": "{{ partitioning_profile_last_partition_end }}" } {% endif %} {% if partitioning_profile == "bios-gpt-mdraid-lvm" %} @@ -84,7 +84,7 @@ { "name": "{{partition_name_prefix}}-vg0-md", "start": "6GiB", - "end": "-1MiB", + "end": "{{ partitioning_profile_last_partition_end }}", "mdraid": "vg0" } {% endif %} @@ -117,7 +117,7 @@ { "name": "{{partition_name_prefix}}-vg0-md", "start": "6GiB", - "end": "-1MiB", + "end": "{{ partitioning_profile_last_partition_end }}", "mdraid": "vg0" } {% endif %}