ZPE Cloud Dynamic Template can be used to apply a dynamic
configuration/script to one or more devices. It can contain variables
which have different values depending on the device it is applied to.
Variables are defined under "Custom Fields" tab in ZPE Cloud Profiles section. The value of the custom field is related to the scope of the device based on the group it belongs to or the site it belongs to. Some custom fields can be targeted only to specific devices.
Example of adding custom field:
Templates are defined in "Profiles::Configuration". To create the dynamic template, select the Add option, ensure "Dynamic Template" checkbox is set and add a script/configuration using custom fields you have created previously. Below is a sample of dynamic template
- set /settings/network_connections/ETH1 ipv4_mode=static
set /settings/network_connections/ETH1 ipv4_address={{mt_eth1_address}}
set /settings/network_connections/ETH1 ipv4_bitmask={{mt_eth1_bitmask}}
commit
This template sets ETH1 interface with static IP. The value is looked up in the variable "mt_eth1_address" which is previously created in Custom Fields section. After the template is saved, you can apply to any device like any other profile.
To understand how the values will change, review this table:
If the dynamic template is applied to the device named MT-THERA, then mt_eth1_address=10.0.1.1, mt_eth1_bitmask=16. If the dynamic template is applied to device named MT-VESUVIUS, then mt_eth1_address=10.0.2.1, mt_eth1_bitmask=16.
Related Articles
How to: Create and Use Custom Fields in ZPE Cloud
Custom fields is a way to make your profiles/templates more dynamic. A custom field is similar to a variable in that it can have different values depending on the scope of the field. You can create a custom field under "Profiles::Custom Fields". ...
How to: Create and apply configurations to your device using ZPE Cloud
Overview ZPE Cloud profiles enable to perform operations to your Nodegrid devices, such as: configurations, custom scripts, backups, software upgrades, and cellular modem firmware upgrades. In this document, we are focusing on the configuration ...
ZPE Cloud ZTP Custom Field Automation Using Service Accounts
Package Name: ZPECloud-ZTP-Script.zip Purpose This document explains how to use the ZPE Cloud Custom Field Automation package to automatically create device custom fields from a CSV file using a ZPE Cloud Service Account. The package allows ...
How to: Enable ZPE Cloud Remote Access...Remotely
You just got your ZPE Nodegrid up and running and it is connected and enrolled in your ZPE Cloud. But you can't access it remotely because the remote access buttons are grayed out. It is online, but no access available. The way to get remote access ...
DHCP ZTP
DHCP ZTP ZTP is a kind of extension to DHCP and ZTP relies on DHCP. If a device is ZTP ready, it will have ZTP vendor specific options that you can do when the device boots up or when its DHCP lease is renewed. The list of options is provided by the ...