inspur.sm.edit_ipv4 – Set ipv4 information.¶
Note
This plugin is part of the inspur.sm collection (version 1.1.2).
To install it use: ansible-galaxy collection install inspur.sm
.
To use it in a playbook, specify: inspur.sm.edit_ipv4
.
New in version 0.1.0: of inspur.sm
Parameters¶
Examples¶
- name: Ipv4 test
hosts: ism
connection: local
gather_facts: no
vars:
ism:
host: "{{ ansible_ssh_host }}"
username: "{{ username }}"
password: "{{ password }}"
tasks:
- name: "Set ipv4 information"
inspur.sm.edit_ipv4:
interface_name: "eth0"
ipv4_status: "disable"
provider: "{{ ism }}"
- name: "Set ipv4 information"
inspur.sm.edit_ipv4:
interface_name: "eth0"
ipv4_status: "enable"
ipv4_dhcp_enable: "dhcp"
provider: "{{ ism }}"
- name: "Set ipv4 information"
inspur.sm.edit_ipv4:
interface_name: "eth0"
ipv4_status: "enable"
ipv4_dhcp_enable: "static"
ipv4_address: "100.2.36.10"
ipv4_subnet: "255.255.255.0"
ipv4_gateway: "100.2.36.1"
provider: "{{ ism }}"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Authors¶
WangBaoshan (@ISIB-group)