IP Fabric Dynamic Attributes
Tip
Please use the main
branch when viewing on the
IP Fabric Documentation Portal for all Integrations. These
documents are not versioned. However, you can find versioned files in the GitLab releases.
ipf_dynamic_attributes
is a Python package designed to automate the creation and management of dynamic attributes in
IP Fabric environments. It provides a flexible configuration system for defining rules, filters, and attribute mappings,
enabling streamlined attribute synchronization and reporting.
Danger
Integrations should be installed outside of the IP Fabric VM unless the IP Fabric team explicitly instructs otherwise.
Warning
Any action on the Command-Line Interface (CLI) using the root
, osadmin
,
or autoboss
account may cause irreversible, detrimental changes to the
product. Actions taken without direct communication with the IP Fabric
Support or Solution Architect teams can render the system unusable.
Features
- Define dynamic attribute rules using YAML, JSON, TOML or Python configuration.
- Support for static and calculated attribute values, including regex extraction and value mapping.
- Support for regex-based searching of device configs.
- Flexible filtering for inventory and device data.
- Default dry-run mode for safe testing.
- Creates a pandas DataFrame for easy data manipulation and reporting.
Minimum Requirements
- Python 3.9+
- IP Fabric version 7.2 or higher
- IP Fabric SDK version 7.2 or higher
Installation
PIP
To install the ipf_dynamic_attributes
package, you can use pip:
pip install ipf_dynamic_attributes
If you would like to output reports in Excel format, you can also install the xlsxwriter
package:
pip install ipf_dynamic_attributes[excel]
Extension
Coming soon…
Running
Command Line Interface (CLI)
To run the utility from the command line, you can use the following command:
> ipf_dynamic_attributes <path_to_config_file>
For full usage information, you can run -h|--help
:
> ipf_dynamic_attributes -h
usage: ipf_dynamic_attributes.cmd [-h] [-f {csv,json,excel}] [-o OUTFILE] [filename]
IP Fabric Dynamic Attribute.
positional arguments:
filename Configuration filename, defaults to 'config.yml'.
options:
-h, --help show this help message and exit
-f {csv,json,excel}, --format {csv,json,excel}
Output format for the report. Default is 'csv'. Use 'json' for JSON output.
-o OUTFILE, --outfile OUTFILE
Output filename to send report instead of standard out.
This script will run the AttributeSync with the provided configuration file which defaults to 'config.yml'.
You can specify a different configuration file by passing the filename as an argument:
ipf_dynamic_attributes example_configs/mgmt-ip.yml
Extension
Coming soon…
Python Script
See example in GitLab Repository.