Skip to content

Commit

Permalink
fix(bios): merged the reboot code for all the instances
Browse files Browse the repository at this point in the history
Signed-off-by: sakethanne <[email protected]>
  • Loading branch information
Sakethanne authored and glimchb committed Oct 3, 2024
1 parent e4f0390 commit b431b0c
Showing 1 changed file with 2 additions and 17 deletions.
19 changes: 2 additions & 17 deletions ansible/bios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,24 +66,9 @@
password: "{{ ansible_password }}"
register: bios_config_job

- name: Reboot iDRAC systems to apply new BIOS settings
- name: Reboot all systems to apply new BIOS settings
when:
- result.redfish_facts.bios_attribute.entries[0][1].SystemManufacturer is defined
- result.redfish_facts.bios_attribute.entries[0][1].SystemManufacturer == "Dell Inc."
- bios_config_job.changed
community.general.redfish_command:
category: Systems
command: PowerReboot
resource_id: "{{ resource_id }}"
baseuri: "{{ ansible_host }}"
username: "{{ ansible_user }}"
password: "{{ ansible_password }}"

# TODO: Merge two reboot tasks into one. find identifier for iLO in redfish bios attributes
- name: Reboot iLO systems to apply new BIOS settings
when:
- bios_attribute.changed
- inventory_hostname == 'dh2bmc' or inventory_hostname == 'dh3bmc'
- bios_config_job.changed or bios_attribute.changed
community.general.redfish_command:
category: Systems
command: PowerReboot
Expand Down

0 comments on commit b431b0c

Please sign in to comment.