community.general.nios_network – Configure Infoblox NIOS network object¶
Note
This plugin is part of the community.general collection (version 2.5.1).
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.nios_network
.
Synopsis¶
Adds and/or removes instances of network objects from Infoblox NIOS servers. This module manages NIOS
network
objects using the Infoblox WAPI interface over REST.Supports both IPV4 and IPV6 internet protocols
Requirements¶
The below requirements are needed on the host that executes this module.
infoblox-client
Parameters¶
Notes¶
Note
This module must be run locally, which can be achieved by specifying
connection: local
.Please read the Infoblox Guide for more detailed information on how to use Infoblox with Ansible.
Examples¶
- name: Configure a network ipv4
community.general.nios_network:
network: 192.168.10.0/24
comment: this is a test comment
state: present
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Configure a network ipv6
community.general.nios_network:
network: fe80::/64
comment: this is a test comment
state: present
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Set dhcp options for a network ipv4
community.general.nios_network:
network: 192.168.10.0/24
comment: this is a test comment
options:
- name: domain-name
value: ansible.com
state: present
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Remove a network ipv4
community.general.nios_network:
network: 192.168.10.0/24
state: absent
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Configure a ipv4 network container
community.general.nios_network:
network: 192.168.10.0/24
container: true
comment: test network container
state: present
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Configure a ipv6 network container
community.general.nios_network:
network: fe80::/64
container: true
comment: test network container
state: present
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
- name: Remove a ipv4 network container
community.general.nios_network:
networkr: 192.168.10.0/24
container: true
comment: test network container
state: absent
provider:
host: "{{ inventory_hostname_short }}"
username: admin
password: admin
connection: local
Authors¶
Peter Sprygada (@privateip)