For Creating and Configuring Service Templates, please review the KB > How to add Service Templates
The order of Templates is a critical factor to consider before committing a template on a device/device group.
For version 21.x.x and above, the order can be configured (rearranged) via
Configuration > Devices > Device Groups > [Name] > Post Staging Template Association
Use Case
For instance, if a configuration parameter (let's say a rule in NGFW) in different templates overlap with each other. The Director uses this templates order to determine the preference of rules. The templates are merged/overwritten in the order of their configured priority.
Note: parameters in last template take precedence over other templates. This is applicable for both Device workflow as well as Device group.
For example, in the screenshot below we see the order of NextGen Firewall service templates associated with the Device Group. Where the template BLP_ST2 will take precedence and therefore applied first in the configured policy rules.
Service Templates