Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this mode, you can set variables for the specific device which was selected when you opened the variable edit window. You can simple specify variables in a "key=value" format. If any variables are already present on the device, they will be loaded into the edit window for you. Here is an example of how variable configuration on a single device would look like:

Code Block
languagetext
variable_name = variable_value
foo = bar
hostname = router

The above configuration would set 3 variables for the selected device, "variable_name", "foo" and "hostname". When saving variables, omitting any existing variables remove those variables. To simplify - when you save variables for a device, all existing variables will be removed, and then variables will be set to the device as provided in the edit window.

Bulk (multi-device) variable edit

...

Please note that when saving devices in bulk edit mode, omitting variables for devices which already have variables present will remove those variables. To simplify - if you save variables for a device devices in bulk edit mode, all existing variables from each specified device will be removed, and then variables will be set to the device devices as provided from the new configuration.

Variable formatting

The variable name, as well as the variable value will have both their leading and tailing white-space removed. All of these declarations as valid, and equal:

Code Block
hostname=router1
hostname = router1
hostname= router1

All of the above will result in a variable with name "hostname" and value "router1" created. It is not possible to declare variables which contain leading or tailing spaces. Spaces inside both variable names and values are however fully supported.

Using variables in Config Push

...