add pvsqueeze.sh script, and execute it prior to ALL bigboot executions

This commit is contained in:
2024-10-14 14:24:28 -04:00
parent 0076a60651
commit af38c279da
2 changed files with 79 additions and 5 deletions

View File

@ -31,13 +31,19 @@
when:
- bigboot_data[inventory_hostname]['bigboot_execute_shrink_lv'] | default(false) | bool
- name: Expand the /boot partition as requested
ansible.builtin.import_role:
name: infra.lvm_snapshots.bigboot
vars:
bigboot_partition_size: "{{ bigboot_size_target }}"
- name: Shift free extents and expand /boot
when:
- bigboot_data[inventory_hostname]['bigboot_execute_bigboot'] | bool
block:
- name: Shift free extents to end of PV
ansible.builtin.script: "scripts/pvsqueeze.sh {{ bigboot_data[inventory_hostname]['bigboot_pv'] }}"
register: bigboot_pvsqueeze
- name: Expand the /boot partition as requested
ansible.builtin.import_role:
name: infra.lvm_snapshots.bigboot
vars:
bigboot_partition_size: "{{ bigboot_size_target }}"
- name: Restore service state for disabled services
ansible.builtin.import_tasks: tasks/restore_services.yml