This Ansible playbook automates the process of backing up device configurations in your network inventory. It is designed to work with Catalyst Center Release version 2.3.7.6 or later.
2.3.7.6 and above
device_configs_backup_details specifies the devices and their details to include in the backup.
Refer to the official documentation for detailed information on defining workflows: https://galaxy.ansible.com/ui/repo/published/cisco/dnac/content/module/device_configs_backup_workflow_manager
Install Ansible if you haven't already Ensure you have network connectivity to your Catalyst Center instance. Checkout the project and playbooks: git@github.com:cisco-en-programmability/catalyst-center-ansible-iac.git
The host_inventory_dnac1/hosts.yml file specifies the connection details (IP address, credentials, etc.) for your Catalyst Center instance. Make sure the dnac_version in this file matches your actual Catalyst Center version.
catalyst_center_hosts:
hosts:
catalyst_center220:
dnac_host: xx.xx.xx.xx.
dnac_password: XXXXXXXX
dnac_port: 443
dnac_timeout: 60
dnac_username: admin
dnac_verify: false
dnac_version: 2.3.7.6
dnac_debug: true
dnac_log_level: INFO
dnac_log: true
The workflows/device_config_backup/vars/device_config_backup_workflow_input.yml file should be configured with device details Refer to the full workflow specification for detailed instructions on the available options and their structure: https://galaxy.ansible.com/ui/repo/published/cisco/dnac/content/module/device_configs_backup_workflow_manager
Validate the input with schema using yamale
yamale -s workflows/device_config_backup/schema/device_config_backup_workflow_schema.yml workflows/device_config_backup/vars/device_config_backup_workflow_input.yml
ansible-playbook -i host_inventory_dnac1/hosts.yml workflows/device_config_backup/playbook/device_config_backup_workflow_playbook.yml --e VARS_FILE_PATH=../vars/device_config_backup_workflow_input.yml -vvvv
- Ensure the Catalyst Center version is compatible.
- Carefully configure inventory and input variables.
- Validate input using yamale to prevent errors.
- Review execution logs for troubleshooting.