Debian Codegraph @

ansible_collections/dellemc/powerflex/roles/powerflex_common/tasks/install_packages_VMkernel.yml

raw symbols SCIP
1 ---
2 - name: Get the acceptance level of the ESXi node
3 register: powerflex_common_get_acceptance_output
4 ansible.builtin.shell: >
5 esxcli software acceptance get
6 changed_when: powerflex_common_get_acceptance_output.stdout != 'PartnerSupported'
7
8 - name: Set the acceptance level to PartnerSupported
9 register: powerflex_common_set_acceptance_output
10 ansible.builtin.shell: >
11 esxcli software acceptance set --level=PartnerSupported
12 when: powerflex_common_get_acceptance_output.stdout != 'PartnerSupported'
13 changed_when: powerflex_common_get_acceptance_output.stdout != 'PartnerSupported'
14
15 - name: Copy Esxi component and rpm files
16 ansible.builtin.copy:
17 src: "{{ item }}"
18 dest: "{{ powerflex_common_esxi_files_location }}"
19 mode: "0644"
20 register: powerflex_common_file
21 with_fileglob:
22 - "{{ powerflex_common_file_install_location }}/*{{ file_glob_name }}*"
23 - "{{ powerflex_common_file_install_location }}/{{ file_gpg_name }}*"
24
25 - name: List the zip file
26 register: powerflex_common_package_file
27 ansible.builtin.find:
28 paths: "{{ powerflex_common_esxi_files_location }}"
29 patterns: "*{{ file_glob_name }}*.zip"
30
31 - name: Install SDC package for ESXi
32 register: powerflex_common_install_package_output
33 ansible.builtin.shell: >
34 esxcli software vib install -d {{ powerflex_common_package_file.files[0].path }} --no-sig-check
35 ignore_errors: true
36 changed_when: "'Reboot Required: true' in powerflex_common_install_package_output.stdout"
37
38 - name: Reboot ESXi host
39 register: powerflex_common_reboot_output
40 ansible.builtin.reboot:
41 reboot_timeout: 500
42 msg: "Rebooting the ESXi host."
43 when: "'Reboot Required: true' in powerflex_common_install_package_output.stdout"
44 changed_when: powerflex_common_reboot_output.rebooted
45
46 - name: Ensure the driver is loaded for SDC after reboot
47 register: powerflex_common_loaded_driver_output
48 ansible.builtin.shell: >
49 set -o pipefail && esxcli software vib list | grep sdc
50 changed_when: powerflex_common_loaded_driver_output.stdout_lines | length == 0