--- - name: Configure Dell Server with OpenManage Ansible Modules hosts: - host001 # these are required because the module is running locally and # connecting to the iDRAC over HTTP/HTTPS gather_facts: false connection: local vars: common_idrac_settings: &common_idrac_settings idrac_ip: "{{ ipv6_address }}" idrac_user: "{{ idrac_user }}" idrac_password: "{{ idrac_password }}" validate_certs: false tasks: - name: Set Name dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: "WebServer.1.ManualDNSEntry": "idrac.{{ inventory_hostname }}.sjc001.fritzlab.net" "NIC.1.DNSDomainName": "{{ inventory_hostname }}" "NIC.1.DNSRacName": "{{ inventory_hostname }}" "NICStatic.1.DNSDomainName": "{{ inventory_hostname }}" - name: Set IPv6 Address dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: "IPv6.1.Enable": "Enabled" "IPv6Static.1.DNSFromDHCP6": "Disabled" "IPv6.1.AutoConfig": "Disabled" "IPv6Static.1.Address1": "{{ ipv6_address }}" "IPv6Static.1.PrefixLength": "{{ ipv6_prefix_len }}" "IPv6Static.1.Gateway": "{{ ipv6_gateway }}" "IPv6Static.1.DNS1": "{{ ipv6_dns_1 }}" - name: Set IPv4 Address dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: "IPv4.1.Enable": "Enabled" "IPv4.1.DHCPEnable": "Disabled" "IPv4.1.DNSFromDHCP": "Disabled" "IPv4Static.1.Address": "{{ ipv4_address }}" "IPv4Static.1.DNS1": "{{ ipv4_dns_1 }}" "IPv4Static.1.Gateway": "{{ ipv4_gateway }}" "IPv4Static.1.Netmask": "{{ ipv4_mask }}" - name: Set SNMP Settings dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: # pollers settings "SNMPAlert.1.Destination": "" "SNMPAlert.1.SNMPv3Username": "" "SNMPAlert.2.Destination": "" "SNMPAlert.2.SNMPv3Username": "" "SNMPAlert.3.Destination": "" "SNMPAlert.3.SNMPv3Username": "" "SNMPAlert.4.Destination": "" "SNMPAlert.4.SNMPv3Username": "" "SNMPAlert.5.Destination": "::" "SNMPAlert.5.SNMPv3Username": "" "SNMPAlert.6.Destination": "::" "SNMPAlert.6.SNMPv3Username": "" "SNMPAlert.7.Destination": "::" "SNMPAlert.7.SNMPv3Username": "" "SNMPAlert.8.Destination": "::" "SNMPAlert.8.SNMPv3Username": "" # trap settings "SNMPTrapIPv4.1.DestIPv4Addr": "{{ snmp_trap_dst_ipv4_1 }}" "SNMPTrapIPv4.2.DestIPv4Addr": "0.0.0.0" "SNMPTrapIPv4.3.DestIPv4Addr": "0.0.0.0" "SNMPTrapIPv4.4.DestIPv4Addr": "0.0.0.0" "SNMPTrapIPv6.1.DestIPv6Addr": "::" "SNMPTrapIPv6.2.DestIPv6Addr": "::" "SNMPTrapIPv6.3.DestIPv6Addr": "::" - name: Auto Attach Virtual Media dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: "VirtualMedia.1.Attached": "AutoAttach" - name: Disable auto discovery dellemc.openmanage.idrac_attributes: <<: *common_idrac_settings idrac_attributes: "Autodiscovery.1.EnableIPChangeAnnounce": "Disabled" "Autodiscovery.1.EnableIPChangeAnnounceFromDHCP": "Enabled" "Autodiscovery.1.EnableIPChangeAnnounceFromUnicastDNS": "Enabled" "Autodiscovery.1.EnableIPChangeAnnounceFrommDNS": "Enabled" "Autodiscovery.1.SendTestAnnouncement": "Disabled"