Workflow to Run Config Scripts

Complete the following tasks to provision config scripts:

  1. Enable the config scripts feature—Globally activate the config scripts feature on the router using configuration validation scripts command.

  2. Download the script—Store the config script on an HTTP server or copy to the hard disk of the router. Add the config script from the HTTP server to the script management repository (harddisk:/mirror/script-mgmt) on the router using the script add config command.

  3. Validate the script—Check script integrity and authenticity using the script config script.py checksum command. A script cannot be used unless the checksum is configured. After the checksum is configured, the script is active.

    Note: A config script is invoked automatically when you validate or commit a configuration change to modify the candidate configuration.

  4. Validate the configuration—Ensure that the configuration changes comply with the predefined conditions in the script and uncover potential errors using validate config-scripts apply-policy-modifications command.

  5. View the script execution details—Retrieve the operational data using the show operational Config Global Validation Script Execution command.

The following image shows a workflow diagram representing the steps involved in using a config script:

For more information about performing the workflow, managing Config scripts, and viewing examples, see the Automation Scripts chapter based on the platform: