dell/redfish-ansible-module

Skip execution if the same configuration is already set

rht-jbittner opened this issue · 1 comments

Hi,
I would like to ask you to implement option check before executing change command. For example:

  1. run playbook with some bios config sets
  2. wait until reboot is done
  3. run same playbook from 1) with same settings

Server gets rebooted again.
It would be great to check system settings value before forcefully apply same setting and again reboot server.

I am using this to have requested functionality, but I think it should be build-in in redfish_config module.

- name: Set Secure boot state
  redfish_config:
    category: Systems
    command: SetBiosAttributes
    bios_attr_name: SecureBoot
    bios_attr_value: "{{ idrac_secure_boot_state }}"
    baseuri: "{{ baseuri }}"
    user: "{{ user }}"
    password: "{{ password }}"
  when: ansible_facts.redfish_facts.bios_attribute.entries.SecureBoot != idrac_secure_boot_state
  notify:
    - Add to BIOS queue

This is already done, please use modules in http://github.com/ansible/ansible. Please note that modules in this git repo are no longer being updated. Please refer to ansible/ansible#47462.