initial changes and cleanup prior to service management code
This commit is contained in:
37
bigboot-check-device-debug.yml
Normal file
37
bigboot-check-device-debug.yml
Normal file
@ -0,0 +1,37 @@
|
||||
---
|
||||
- name: Capture boot and logical volume information
|
||||
hosts: all
|
||||
become: true
|
||||
gather_facts: true
|
||||
strategy: free
|
||||
|
||||
vars:
|
||||
shrink_lv_device: "/dev/mapper/system-root"
|
||||
|
||||
tasks:
|
||||
- name: Get the mount point info
|
||||
ansible.builtin.set_fact:
|
||||
shrink_lv_mount_info: "{{ ansible_facts.mounts | selectattr('device', 'equalto', shrink_lv_device) }}"
|
||||
|
||||
- name: Assert that the mount point exists
|
||||
ansible.builtin.assert:
|
||||
that: (shrink_lv_mount_info | length) == 1
|
||||
fail_msg: "Mount point {{ shrink_lv_device }} does not exist"
|
||||
|
||||
- name: Get logical volume mount information
|
||||
ansible.builtin.set_fact:
|
||||
bigboot_lv_info: "{{ ansible_facts.mounts \
|
||||
| selectattr('device', 'equalto', shrink_lv_device) }}"
|
||||
|
||||
- name: Assert that the mount point exists
|
||||
ansible.builtin.assert:
|
||||
that: (bigboot_lv_info | length) == 1
|
||||
fail_msg: "Mount point {{ shrink_lv_device }} does not exist"
|
||||
|
||||
- name: Debug shrink_lv_mount_info
|
||||
ansible.builtin.debug:
|
||||
var: shrink_lv_mount_info
|
||||
|
||||
- name: Debug bigboot_lv_info
|
||||
ansible.builtin.debug:
|
||||
var: bigboot_lv_info
|
Reference in New Issue
Block a user