summaryrefslogtreecommitdiffstats
path: root/ansible_collections/cisco/intersight/playbooks/server_firmware.yml
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-18 05:52:22 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-18 05:52:22 +0000
commit38b7c80217c4e72b1d8988eb1e60bb6e77334114 (patch)
tree356e9fd3762877d07cde52d21e77070aeff7e789 /ansible_collections/cisco/intersight/playbooks/server_firmware.yml
parentAdding upstream version 7.7.0+dfsg. (diff)
downloadansible-38b7c80217c4e72b1d8988eb1e60bb6e77334114.tar.xz
ansible-38b7c80217c4e72b1d8988eb1e60bb6e77334114.zip
Adding upstream version 9.4.0+dfsg.upstream/9.4.0+dfsg
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'ansible_collections/cisco/intersight/playbooks/server_firmware.yml')
-rw-r--r--ansible_collections/cisco/intersight/playbooks/server_firmware.yml31
1 files changed, 19 insertions, 12 deletions
diff --git a/ansible_collections/cisco/intersight/playbooks/server_firmware.yml b/ansible_collections/cisco/intersight/playbooks/server_firmware.yml
index 6888fa781..f07bcb3e2 100644
--- a/ansible_collections/cisco/intersight/playbooks/server_firmware.yml
+++ b/ansible_collections/cisco/intersight/playbooks/server_firmware.yml
@@ -5,7 +5,8 @@
# ansible-playbook ... -e group=<your host group>
# e.g., ansible-playbook server_profiles.yml -e group=TME_Demo
#
-- hosts: "{{ group | default('Intersight_Servers') }}"
+- name: Update server firmware
+ hosts: "{{ group | default('Intersight_Servers') }}"
connection: local
gather_facts: false
vars:
@@ -20,14 +21,16 @@
file_share: 172.28.224.77/mnt/SHARE/ISOS/HUU
tasks:
# Edit FW to be used as needed for server type below
- - set_fact:
- file_name: "ucs-c220m4-huu-{{ fw_version | replace('(','.') | replace(')','') }}.iso"
+ - name: Set file name
+ ansible.builtin.set_fact:
+ file_name: "ucs-c220m4-huu-{{ fw_version | replace('(', '.') | replace(')', '') }}.iso"
supported_models:
- UCSC-C220-M4L
- UCSC-C220-M4S
when: model is search("UCSC-C220-M4.*")
- - set_fact:
- file_name: "ucs-c240m4-huu-{{ fw_version | replace('(','.') | replace(')','') }}.iso"
+ - name: Set file name
+ ansible.builtin.set_fact:
+ file_name: "ucs-c240m4-huu-{{ fw_version | replace('(', '.') | replace(')', '') }}.iso"
supported_models:
- UCSC-C240-M4L
- UCSC-C240-M4S
@@ -35,8 +38,9 @@
- UCSC-C240-M4SNEBS
- UCSC-C240-M4S2
when: model is search("UCSC-C240-M4.*")
- - set_fact:
- file_name: "ucs-c240m5-huu-{{ fw_version | replace('(','.') | replace(')','') }}.iso"
+ - name: Set file name
+ ansible.builtin.set_fact:
+ file_name: "ucs-c240m5-huu-{{ fw_version | replace('(', '.') | replace(')', '') }}.iso"
supported_models:
- UCSC-C240-M5S
- UCSC-C240-M5L
@@ -49,8 +53,9 @@
- HX240C-M5SD
- HXAF240C-M5SD
when: model is search("UCSC-C240-M5.*")
- - set_fact:
- file_name: "ucs-c220m5-huu-{{ fw_version | replace('(','.') | replace(')','') }}.iso"
+ - name: Set file name
+ ansible.builtin.set_fact:
+ file_name: "ucs-c220m5-huu-{{ fw_version | replace('(', '.') | replace(')', '') }}.iso"
supported_models:
- UCSC-C220-M5SX
- UCSC-C220-M5L
@@ -58,15 +63,17 @@
- HX220C-M5SX
- HXAF220C-M5SX
when: model is search("UCSC-C220-M5.*")
- - set_fact:
+ - name: Set file location
+ ansible.builtin.set_fact:
file_location: "{{ file_share }}/{{ file_name }}"
# Set the distributable type based on the management mode and server type
- - set_fact:
+ - name: Set firmware distributable type
+ ansible.builtin.set_fact:
dist_type: STANDALONE
when: mode == 'Intersight' or mode == 'IntersightStandalone'
# Get a user defined FW version
- name: Get Moid of user defined FW version
- intersight_rest_api:
+ cisco.intersight.intersight_rest_api:
<<: *api_info
resource_path: /firmware/Distributables
query_params: