Home

Awesome

Infoblox NIOS Modules for Ansible Collections

Infoblox NIOS Modules for Ansible Collections enable the management of your NIOS objects through APIs.

Description

Infoblox NIOS Modules for Ansible Collections facilitate the DNS and IPAM automation of VM workloads that are deployed across multiple platforms. The nios_modules collection consists of modules and plug-ins required to manage the networks, IP addresses, and DNS records in NIOS. The collection is hosted on Ansible Galaxy under infoblox.nios_modules.

Modules Overview

The infoblox.nios_modules collection has the following content:

Modules

Plugins

Requirements

Install the infoblox-client WAPI package. To install, run the following command:

pip install infoblox-client==0.6.0

Installation

To install nios module with the Ansible Galaxy command-line tool:

ansible-galaxy collection install infoblox.nios_modules

You can also include it in a requirements.yml file and install it with ansible-galaxy collection install -r requirements.yml, using the format:

collections:
    - name: infoblox.nios_modules

Note that if you install any collection from Ansible Galaxy, they will not be upgraded automatically when you upgrade the Ansible package. To upgrade the collection to the latest available version, run the following command:

ansible-galaxy collection install infoblox.nios_modules --upgrade

You can also install a specific version of the collection. For example, due to an issue of the latest version, if you need to downgrade the collection to a prior version, use the following command to install the specific version:

ansible-galaxy collection install infoblox.nios_modules:==<version>

See using Ansible collections for more details.

Installation from GitHub

$ ansible-galaxy collection install git+https://github.com/infobloxopen/infoblox-ansible.git,master

Please refer to our Ansible deployment guide for more details.

Use Cases

1. Automated DNS Record Management

Description: Automatically create, update, and delete DNS records in Infoblox NIOS based on changes in your infrastructure.

Example:

- name: Create a DNS A record
  infoblox.nios_modules.nios_a_record:
    name: "host.example.com"
    ipv4addr: "192.168.1.10"
    state: "present"

2. IP Address Allocation

Description: Dynamically allocate and manage IP addresses for virtual machines and other devices in your network.

Example:

- name: Allocate an IP address
  infoblox.nios_modules.nios_fixed_address:
    ipv4addr: "192.168.1.20"
    mac: "00:50:56:00:00:01"
    state: "present"

3. Network Management

Description: Create and manage network segments and subnets within Infoblox NIOS.

Example:

- name: Create a network
  infoblox.nios_modules.nios_network:
    network: "192.168.2.0/24"
    comment: "Development network"
    state: "present"

4. DHCP Scope Management

Description: Manage DHCP scopes to ensure efficient IP address distribution and avoid conflicts.

Example:

- name: Create a DHCP range
  infoblox.nios_modules.nios_range:
    network: "192.168.3.0/24"
    start_addr: "192.168.3.10"
    end_addr: "192.168.3.100"
    state: "present"

5. DTC Object Management

Description: Manage DNS Traffic Control (DTC) objects to optimize traffic distribution and ensure high availability.

Example:

- name: Create a DTC Pool
  infoblox.nios_modules.nios_dtc_pool:
    name: "example_pool"
    lb_method: "round_robin"
    state: "present"

6. Lookups

Description: Perform lookups to retrieve information about existing NIOS objects.

Example:

- name: fetch the default dns view
  ansible.builtin.set_fact:
    dns_views: "{{ lookup('infoblox.nios_modules.nios_lookup', 'view', filter={'name': 'default'},
                  provider={'host': 'nios01', 'username': 'admin', 'password': 'password'}) }}"

7. Next Available Functionality

Description: Retrieve the next available IP address or network in a specified range or network.

Example:

- name: return next available IP address for network 192.168.10.0/24
  ansible.builtin.set_fact:
    ipaddr: "{{ lookup('infoblox.nios_modules.nios_next_ip', '192.168.10.0/24', provider={'host': 'nios01', 'username': 'admin', 'password': 'password'}) }}"

For more detailed examples and playbooks, refer to the playbooks directory in the infoblox-ansible repository.

Testing

The collection has been tested in the following environments:

Known Exceptions and Workarounds

For detailed information on testing and performance, refer to the tests directory in the infoblox-ansible repository.

Contributing

We welcome your contributions to Infoblox Nios Modules. See CONTRIBUTING.md for more details.

Support

Supported Versions

Infoblox NIOS Modules for Ansible Collections supports the following versions:

How to Get Support

If you need assistance with the Infoblox NIOS Modules, you can get support through the following channels:

For any other inquiries, please refer to the Infoblox Contact Page.

Release Notes and Roadmap

For detailed information about the latest updates, new features, bug fixes, and improvements, please visit our Changelog.

Related Information

For more detailed documentation and examples, refer to the following resources:

License Information

This code is published under GPL v3.0 COPYING

Issues or RFEs

You can open an issue or request for enhancement here