- 06 Apr 2024
-
DarkLight
-
PDF
IAG 2022.1+ Execution Flow by Role Type
- Updated on 06 Apr 2024
-
DarkLight
-
PDF
Execution Flow By Role Type
Depending on the inventory variables present, the above roles will defer to one of three flows: fully supported, semi-supported, and custom/unsupported.
Fully Supported (Ansible-based)
The Ansible-based roles are for use with our explicit list of fully supported devices located in our support documentation. This list includes devices such as, but not limited to: Arista EOS, Alcatel SROS, Aruba CX, Cisco ASA/IOS/Nexus/IOS-XR, F5 Bigip, Junos JunOS. Support documentation can be found at IAP Compatibility.
Executing a role against a fully supported device enables users to utilize the full suite of Automation Gateway and Automation Platform features, such as these roles, Configuration Manager, Golden Configuration, and Command Templates.
Requirements
The device is explicitly in Itential's list of supported devices, and you can successfully connect to the device via Ansible's connection parameters.
Important Variables
- The
ansible_network_os
variable must match a valid Ansible OS type, and it must be in the list of devices supported by Itential, such asios
for Cisco IOS.
Example Host
{
"name": "Example_IOS",
"ansible_host": "ios.example.com",
"ansible_connection": "network_cli",
"ansible_network_os": "ios",
"ansible_user": "username",
"ansible_password": "password",
"ansible_become": true,
"ansible_become_password": "password"
}
Semi-Supported (Netmiko-based)
The Netmiko-based roles are for use with devices that do not fall under the fully supported category, but which have prebuilt support from the Netmiko library. This list is much greater than the fully supported list, however it has its own caveats and levels of support from that library. See Netmiko Platforms for additional information regarding the device_type
variable and options.
Executing a role against a semi-supported device enables users to utilize the majority of Automation Gateway and Automation Platform features, such as these roles and Configuration Manager/Golden Configuration. However, it does not come with any guarantee that Netmiko can successfully connect to the device, or operate against the device exactly as a user may expect. Instead, it provides a reasonable expectation that if Netmiko has a device_type
for your device, you can very easily enable connectivity and test the available functionality (such as sending commands, updating configuration).
Requirements
The device is not in Itential's list of supported devices, and you can successfully connect to the device via Netmiko's connection parameters. You are willing to accept that a certain amount of research and customization is required to enable connectivity and functionality, but that once enabled, it will work with the majority of Automation Gateway and Automation Platform features.
The Itential Netmiko roles can be executed through the main itential_*
roles or directly via the itential_netmiko_*
roles.
Important Variables
- The
ansible_network_os
variable must not match the name of a fully supported device and should generally be omitted to avoid confusion and ensure the correct execution path is followed. - A local connection type is required; therefore
ansible_connection
must be set tolocal
. - Either
provider.device_type
ornetmiko_device_type
must be a valid netmikodevice_type
.
Example Host (Explicit Usage)
The following example host shows an explicit set of Netmiko-related variables nested under the provider
object so that it is very clear that this host is meant to be used only with the Netmiko roles.
{
"name": "Example_IOS",
"variables": {
"**********REQUIRED VARIABLES**********": "",
"ansible_connection": "local",
"provider": {
"host": "ios.example.com",
"device_type": "cisco_ios",
"username": "username",
"password": "password"
},
"**********END REQUIRED VARIABLES**********": "",
"**********OPTIONAL VARIABLES**********": "",
"ansible_host": "ios.example.com",
"ansible_port": 22,
"ansible_network_os": "cisco_ios",
"end_command": "end",
"save_command": "commit apply",
"get_config_command": "show run",
"get_state_command": "show version",
"**********END OPTIONAL VARIABLES**********": ""
}
}
Example Host (Implicit Usage)
The following example host shows an implicit set of Netmiko-related variables which are declared outside of the provider
object. This method allows the user to use mostly Ansible variables, which are converted into the provider
object in the background, with the addition of netmiko_device_type
so that it is correctly routed to the Netmiko roles.
{
"name": "Example_IOS",
"variables": {
"**********REQUIRED VARIABLES**********": "",
"ansible_connection": "local",
"ansible_host": "ios.example.com",
"ansible_user": "username",
"ansible_password": "password",
"netmiko_device_type": "cisco_ios",
"**********END REQUIRED VARIABLES**********": "",
"**********OPTIONAL VARIABLES**********": "",
"ansible_port": 22,
"ansible_network_os": "cisco_ios",
"end_command": "end",
"save_command": "commit apply",
"get_config_command": "show run",
"get_state_command": "show version",
"**********END OPTIONAL VARIABLES**********": ""
}
}
Unsupported (Custom)
The unsupported, custom role types are only for use with devices that do not fall under the fully supported list and cannot be configured to work with Netmiko via the semi-supported role type. This execution method requires that the user copy a role template and create their own Ansible role, modules, etc to enable connectivity and functionality with their unsupported device.
Executing a role against an unsupported device comes with no expectation that the device will be able to utilize the full suite of Automation Gateway and Automation Platform features, such as these roles, Configuration Manager, Golden Configuration and Command Templates.
Requirements
- The device in question cannot be executed against the fully supported or semi-supported roles.
- The
ansible_network_os
variable must not be in the list of supported device types and should instead be a made-up value that matches the custom role you created (see the templates for additional information).
Example Host
{
"name": "Example_IOS",
"ansible_host": "ios.example.com",
"ansible_connection": "???",
"ansible_network_os": "custom_unsupported_ios",
"...any other custom variables for your custom role...": "..."
}