Important

   

Starting version 8.9.03, BMC Network Automation is renamed to TrueSight Network Automation. This space contains information about BMC Network Automation 8.9.02 and previous versions. For TrueSight Network Automation 8.9.03 and later releases, see the TrueSight Network Automation documentation.

Adding a template

To add a template to your environment, you can choose one of the following methods:

To create a new template

  1. Open the Templates page by navigating to Network > Scripts > Templates.
  2. Click the Add button to open the Add Template page.
  3. In the Details tab, enter information in the following fields:
    • Name: Enter a unique name to identify the template.
    • Annotation: (Optional) Enter an annotation to identify the template.
    • Validate Substitution Parameters: (Optional) Select this option if BMC Network Automation should validate substitution parameter syntax before saving the template. For more information, see Using substitution parameters in templates.
  4. Click the Contents tab to define the template contents.
    A template can contain the contents of multiple scripts. Each script has a unique Device Type and OS version. This enables you to organize common scripts across multiple vendors as a single template. For more information, see Understanding template formatting.
  5. To add a script, click Add.
  6. Enter the following information, as needed:
    • Device Type: Enter the device type compatible with this template.
    • Minimum OS Version: Enter the minimal OS version for which this Template is compatible. Enter * to specify any major, minor, or build.
    • Maximum OS Version: Enter the maximum OS version for which this Template is compatible. Enter * to specify any major, minor, or build.
    • Injection Template: Select this check box if you want to inject the Deploy to Active action with device type command elements, such as interaction httpinteraction condition , or  loops  and modify the device configuration by using APIs. For more information about injection templates, see Changing device configurations.
    • Contents: Enter the configuration commands that are to be sent to a device during a Deploy to Stored or Deploy to Active operation. If you have copied an existing configuration, ensure that device specific configuration parameters (for example, hostname) are changed to match the target device.
  7. When you are finished entering the script, click Enter and then Save to save the changes.
    The script is added to the template.

To create a template based on an existing configuration

  1. Open the device with the desired configuration for editing, as described in Editing devices.
  2. Select the Configurations tab.

  3. Select a Running, Startup, or other appropriate configuration, and click Create Template. The configuration file is copied to the Contents tab of the new template. The Add Template page is displayed.

  4. In the Details tab, enter information in the following fields:
    • Name: Enter a unique name to identify the template.
    • Annotation: (Optional) Enter an annotation to identify the template.
    • Validate Substitution Parameters: (Optional) Select if BMC Network Automation should validate substitution parameter syntax before saving the template. For more information, see Using substitution parameters in templates.
  5. Select the Contents tab to view or edit the template.
    A template can contain the contents of multiple scripts. Each script has a unique Device Type and OS version. This enables you to organize common scripts across multiple vendors as a single template. For more information, see Understanding template formatting.

     

  6. To modify the list of scripts, perform one of the following actions:
    • To add a script, select the script, and click Add.
    • To edit a script, select the script, and click Edit.

  7. Enter the following information, as needed:
    • Device Type: Enter the device type compatible with this template.
    • Minimum OS Version: Enter the minimal OS version for which this Template is compatible. Enter * to specify any major, minor, or build.
    • Maximum OS Version: Enter the maximum OS version for which this Template is compatible. Enter * to specify any major, minor, or build.
    • Injection Template: Select this check box if you want to inject the Deploy to Active action with device type command elements, such as interaction httpinteraction condition , or loops and modify the device configuration by using APIs. For more information about injection templates, see Changing device configurations.

    • Contents: Enter the configuration commands that are to be sent to a device during a Deploy to Stored or Deploy to Active operation. If you have copied an existing configuration, ensure that device specific configuration parameters (for example, hostname) are changed to match the target device.
  8. When you are finished editing the script, ensure you click Enter and then Save to save the changes.
Was this page helpful? Yes No Submitting... Thank you

Comments