Releases: dmulyalin/salt-nornir
Releases · dmulyalin/salt-nornir
0.19.4
0.19.3
FEATURES
- nr.netbox execution module
get_interfaces
added support to cache data received from Netbox using diskcache module - Salt-Nornir robot nr.test added overall tests counter for robot framework outputted logs
- Salt-Nornir robot nr.test added support to wrap commands output per device per-command instead of just per device on robot log output
- Salt-Nornir robot nr.test added CSV results section to robot report to contain results in CSV format
CHANGES
- netbox_secretstore support removed as it is no longer maintained, instead netbox_secrets integration verified with Netbox 3.5
- nr.nornir version report added
diskcache
version
0.19.2
ENHANCEMENTS
- Done testing with Salt 3006
CHANGES
- Enhanced Robot nr.test keyword logging and reporting - now reports have success/failure highlighting, full test suite results returned with collected device output for each test suite.
- Netbox pillar main function enveloped in try/except loop making sure unexpected pillar etrieval failure handled more gracefully.
- Updated dependencies to comply with Salt 3006 static requirements:
- pyyaml from 6.0 to 5.4.1
- requests from 2.28.1 to 2.25.1
- psutil from
>=5.8.*,<=5.9.*
to>=5.8.*,<6.*
- Changes to development environment itself:
- Use
python:3.9-slim-bullseye
as a base image for testing - Updated ceos instances to 4.30.0F
- A number of tests being fixed following above changes
- Changes to install extras:
- 'prodmax' replaced with prodmaxminion and prodmaxmaster
- 'prodmin' replaced with prodminminion and prodminmaster
BUGS
- Updated refresh behavior to preserve worker stats across Nornir refresh, where previously those stats have been set to 0 on each refresh
0.19.1
FEATURES
- nr.netbox
get_interfaces
andget_connetions
added sync argument to store retrieved data in host's inventory - nr.netbox
get_interfaces
andget_connetions
added support to retrieve data for hosts matched by Fx filters - nr.nornir inventory added support for `update_defaults`` function to update in-memory defaults inventory data, #28
CHANGES
- nr.netbox
get_interfaces
andget_connetions
now return dictionary keyd by hostnames - nr.netbox
get_interfaces
andget_connetions
removed device_name argument, instead need to use Fx filters - Updated netbox_utils to support sourcing Netbox URL and Token directly from proxy minion pillar in addition to sourcing it from master's ext_pillar configuration
BUGS
- Fixed Netbox
get_interfaces
inventory items handling when inventory item not assigned to any component
0.19.0
BUGS:
- NETBOX secrets - If uses
secret_name_map: {password: username}
andfetch_password: True
, secret name does not end up in username value, updated code to checksecret_name_map
forusername
andpassword
keys to store secret names accordingly forfetch_username
andfetch_password
cases. - NETBOX secrets - if no plugins defined under secrets section, KeyError raised - updated code to improve error handling by raising RuntimeError with useful message instead of key error
- nr.test suite validation was not working
FEATURES:
- NETBOX secrets - added support to match secret role by secret role slug in addition to secret role name
- Netbox pillar - added
host_primary_ip
parameter to control which primary IP (ip4 or ip6) to use as host's hostname - Netbox pillar - when
host_add_netbox_data
configured, sites now has list of tags retrieved - nr.netbox execution module added
rest
function to retrieve data from Netbox over REST API - Netbox pillar - added support for
netbox_secrets
plugin - Runner - added experimental nr.shell runner function to start interactive shell (using PICLE) based on salt nornir pydantic models
- Execution module nr.test suite argument can now be a string which is either a YAML blob or a Jinja2 template to render to produce YAML blob of tests
- Execution module nr.nornir connect added support for
via
attribute - Execution module nr.nornir connect added support to redipatch connection via terminal server using Netmiko
- Execution module nr.nornir got new read_host_data function to read portions of host inventory data
- Execution modeule nr.test added
tests
argument to support retrieving tests from host's inventory data. also addedstrict
argument to control behavior if tests data not present in host's inventory - Added integration with Robot framework for nr.test function
- Added integration with Robot framework for nr.cli function
- Added new execution module function
nr.network
to implement network related utilites, so far addedresolve_dns
utility.
CHANGES
- Netbox pillar - when
host_add_netbox_data
configured, device tags transformed into a list of tag names instead of list of tags dictionaries - nr.netbox
get_connections
andget_interfaces
fully compatible with Netbox 3.4 only, this is due to changes introduced to GraphQL API on Netbox side - Runner nr.diagram set to increase netmiko read_timeout timer to 120 seconds by default
- Netbox pillar no longer raises KeyError if no platform found for host in Netbox
DOCS
- Converted Netbox Pillar tables to lists of items, as tables did not fit read the docs screen entirely.
0.18.0
BUGS
- Netbox Pillar. Fixed handling of GraphQL queries that have significant number of filters, with previous behaviour query was encoded in parameters and was causing request to fail due to maximum parameters size was exceeded, this fix moves query content into reuqest body.
- Netbox Pillar. Fixed handling of unsupported connections for get_connection function. This function only supports (for now) consoleports, consoleserverport and interface type of terminations, made sure that all other termination types are filtered out.
- Netbox Pillar. Fixed
fetch_username
andfetch_password
handling for actual secret values that are not a path to the secret innb://xyz
format, made sure to ignore them.
CHANGES
- Netbox Pillar. Enhanced handling of hosts encoded in a config context of minion_id device by retrieving all devices details in one query as opposed to previously devices have been retrieved one by one, added tests to test this behaviour.
- Netbox Pillar. On big number of hosts to retrieve from Netbox, minion was timing out, introduced multi-trheading support to speed up the process of retrieving data from Netbox. Adding new parameters
data_retrieval_num_workers
anddata_retrieval_timeout
. - Netbox Utils. Refactored nb_graphql function to support aliases
- Netbox Pillar. Refactored
get_connection
s functions to use GraphQL aliases to request termination points data in single query, as a result instead of 4 queries 2 queries required to retrieve data from Netbox - Netbox Pillar. Refactored
get_interfaces
function to retireve interfaces, ip adresses and inventory items in a single query using aliases, instead of 2 need to send 1 query now. - Netbox Pillar. ENhanced the process of rtetrieving hosts by host filters by packing all filters in a single query using GraphQL alises, now nomatter how many filters defined, all devices retrieved in a single query, while previously it was done one filter by one filter.
- Dependencies updated and tested:
- netmiko 4.1.1 -> 4.1.2
- paramiko 2.11.0 -> 2.12.0
- pynetbox 6.6.2 -> 7.0.0
- tabulate 0.8.10 -> 0.9.0
- lxml 4.9.1 -> 4.9.2
- rich 12.5.1 -> 12.6.0
FEATURES
- Execution Module nr.netbox
query
function added support forqueries
andquery_string
arguments
0.17.2
BUGS
- Execution module nr.test - fix event progress job identity was lacking JID and Username
- Proxy Module - list_hosts improved error handling while nornir workers are refreshing to return friendly message instead of traceback
- Netbox pillar module - improved handling of connections that does not have remote device termination
0.17.1
0.17.0
CHANGES
- nr.test now renders tests suites using SaltStack as opposed to using Jinja2 directly within TestsProcessor, that allows to have access to all SaltStack execution modules functions and have access to wider set of inventory data while generating tests suites
- Because of change 1 nr.test no longer supports
wait_timeout
features - Because of change 1 test
cli
argument now only supportFx
filters attributes everything else is ignored,Fx
filters used in conjunction withsubset
argument to limit the set of tests to run on certain hosts. Instead, additional arguments provided on nr.test call are shared across all nr.cli calls for the tests:
salt nrp1 nr.test suite="salt://tests/suite1.txt" enable=True
enable=True
shared across all suite tests.
- Removed support for netbox_tasks, as respective functionality removed from Nornir-Salt as well, the reason is - this could be replaced by nr.netbox execution module and netbox pillar module
FEATURES
- Execution module nr.test now has
dry_run
argument to return per-host rendered test suites content without running tests - Execution module nr.test test suites rendered using SaltStack renreing system producing per-host test suites to run
- nr.netbox - added new function
query
to run any arbitrary graphql query to Netbox, that would allow to use any Netbox data in Jinja2 templates for renring of configuration or test suites - Nornir-Salt TestsProcessor updated to do tests filtering and now supports
subset
argument - Nornir-Salt TestsProcessor extended to support dictionary test suites keyed by host names
- Execution module nr.netbox and netbox pillar modules updated to use same query function from netbox_utils for interfaces and connection retrieval
- Execution module nr.netbox added
get_interfaces
query - Execution module nr.netbox added
get_connections
query - Salt-Nornir Netbox pillar added
host_add_interfaces_inventory_items
argument to retireve interface inventory items - Salt-Nonir Netbox pillar added secret_name_map parameter to provide capability to record secret names in Nornir inventory.
- Salt-Nonir Netbox pillar netbox_secretsore added url_override parameter to customize secrets plugin url
- Execution module nr.netbox added
update_config_context
function to parse devices config and add it to configration context - Execution module nr.netbox added
update_vrf
function to parse devices config and create/update VRF and RT in Netbox
BUGS
- Fixed nr.workflow state handling of steps that did not match any hosts to make sure we not running that step but going to next one instead.
0.16.1
CHANGES
- Added
termionation_type
andremote_termination_type
to Salt-Nornir Netbox pillar connections dictionary - Changes to introduce support for parsing devices config and pushing it to Netbox, such as added support for new inventory function
list_hosts_platforms
and updated lab setup to include TTP_Templates repository
BUGS
- Fix Salt-Nornir Netbox pillar to properly form host data's "data" key if it does not exists prior, add interfaces and connection were affected in a way that "data" did not exist within host dictionary causing KeyError exception