Updating templates

rzr

New Member
Oct 13, 2016
14
0
1
68
We use scripts to create linked clones and most of the times they depend on the template id.
Often we have to make minor changes to a template.

In order to update a template:
Option1 (the id of the template changes)
- full clone of template
- update clone (add our changes)
- create a template
- new template has a different id
- we have to update our scripts

Option2 (the id of the template stays the same)
- full clone of template
- update clone (add our changes)
- backup the clone
- delete old template
- restore the backup with the id of the first template
- create a template from the restored template


Option1 is messy, because we have to update all our scripts every time.
Option2 takes too much time.

Is there a better way?
 
just pass all the arguments to script rather than hard code them inside
 
The scripts that create the clones are separate from the ones that update the templates. We update the clones only when we change something.