To create a configuration template, you need to start with a CLI script. The object names in a CLI script are replaced with tokens. Each token includes three tags: a name, a description and an optional default value. The CLI scripts with tokens are saved as a text file. Here is an example of a single Token:
<NAME:name,DESCRIPTION:description,DEFAULT:default>
NAME, DESCRIPTION, and DEFAULT labels should be in ALL CAPS.
Example token to create an Address Context:
set addressContext <NAME:Address_Context,DESCRIPTION:The name of the address context to create,DEFAULT:AC_1>
When the above template (with token) is imported using the Import tool, a row is created in the token table as shown here:
If the same token is used repeatedly in a template, the description and the default value only need to be specified the the first time the token is used. Subsequent times the same token is used, only the NAME parameter needs to be specified.
If a Default value is not specified, then the corresponding text field in the configuration template import tool will be blank.
Here is an example of a configuration file to set up a basic call (saved as a text file):
configure set addressContext <NAME:Address_Context,DESCRIPTION:The name of the address context to create,DEFAULT:AC_1> commit set addressContext <NAME:Address_Context> ipInterfaceGroup <NAME:IP_Interface_Group,DESCRIPTION:The name of the IP Interface Group, DEFAULT:IG_1> ipInterface <NAME:IP_Interface,DESCRIPTION:The name of the IP Interface to create,DEFAULT:IF_1> portName <NAME:Port_Name,DESCRIPTION:The packet port for the IP Interface: pkt0, pkt1, pkt2, pkt3,DEFAULT:pkt0> ipAddress <NAME:IP_Interface_IP_Address,DESCRIPTION:The IP Address of the IP Interface,DEFAULT:> prefix <NAME:IP_Interface_IP_Address_Prefix,DESCRIPTION: The prefix for he IP Interface IP address.,DEFAULT:> ceName <NAME:CE_Name,DESCRIPTION:The CE name of the SBC.,DEFAULT:> vlanTag <NAME:Vlan_Tag,DESCRIPTION:The VLAN tag for the IP Interface,DEFAULT:100> state disabled mode outOfService commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name, DESCRIPTION: The name of the zone, DEFAULT:Zone_1> id <NAME:Zone_ID, DESCRIPTION: The Zone ID number, DEFAULT:100 > sipSigPort <NAME:SIP_Sig_Port_ID, DESCRIPTION: The ID number of the SIP Signaling Port, DEFAULT:101 > ipInterfaceGroupName <NAME:IP_Interface_Group> ipAddressV4 <NAME:SIP_Sig_Port_ID_IP_Address, DESCRIPTION: The IP address of the SIP Signaling Port, DEFAULT:> portNumber <NAME:SIP_Sig_Port_Number, DESCRIPTION: The port number of the SIP Signaling Port, DEFAULT:5060 > transportProtocolsAllowed <NAME:Transport_Protocol, DESCRIPTION: The allowed transport protocols for the SIP Signaling Port, DEFAULT:sip-udp > commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name> id <NAME:Zone_ID> sipSigPort <NAME:SIP_Sig_Port_ID> state disabled mode outOfService commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name> sipTrunkGroup <NAME:SIP_Trunk_Group_Name, DESCRIPTION: The name of the SIP Trunk Group, DEFAULT:SIP_TG_1> media mediaIpInterfaceGroupName <NAME:IP_Interface_Group> commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name> sipTrunkGroup <NAME:SIP_Trunk_Group_Name> signaling timers sessionKeepalive <NAME:Session_Keep_Alive_Time, DESCRIPTION:The session keep alive time for the SIP Trunk Group , DEFAULT:0> commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name> sipTrunkGroup <NAME:SIP_Trunk_Group_Name> ingressIpPrefix <NAME:Ingress_IP_Prefix_IP_Address, DESCRIPTION: The IP address of the Ingress IP Prefix, DEFAULT:> <NAME:Ingress_IP_Prefix_Length, DESCRIPTION:The length of the Ingress IP Prefix , DEFAULT:> commit set addressContext <NAME:Address_Context> zone <NAME:Zone_Name> sipTrunkGroup <NAME:SIP_Trunk_Group_Name> state disabled mode outOfService commit
When the above configuration file is imported using the Import tool, the following fields are created on the Import template panel:
Refer to Configuration Template Import (EMA) - Import Template to know more on how to import a configuration template successfully.