sagcc create templates snapshot
DEPRECATED. Use composite templates to provision installations.
Platform Manager creates a new template based on an existing managed installation, archives the new template and transfers the archive file to the Command Central file system.
Syntax
Command Central syntax:
With parameters:
sagcc create templates snapshot alias=template_alias
nodeAlias=node_alias options=[PRODUCTS,CONFIGURATION,FIXES,FILES]
[sharedsecret=text_string]
doOverwrite=true | false [command options]
With input file:
sagcc create templates snapshot
{--input | -i} filename{.xml | .json} [command options]
Platform Manager syntax:
With parameters:
sagcc create templates alias=template_alias
options=[PRODUCTS,CONFIGURATION,FIXES,FILES] [sharedsecret=text_string]
doOverwrite=true | false
[command options]
With input file:
sagcc create templates
{--input | -i} filename{.xml | .json} [command options]
Arguments and Options
Argument or Option | Description |
alias=template_alias | Required. The name of the template to create. |
nodeAlias=node_alias | Required. Only for Command Central. Specifies the alias name of the Platform Manager from which you want to create the template. |
options=[PRODUCTS, CONFIGURATION,FIXES,FILES]
| Required. The type of content to include in the new template. If you want to include more than one type of content in the template, you must repeat this parameter for each content type that you want to include. |
[sharedsecret=text_string] | Optional. A shared secret that serves as password for encrypting and decrypting passwords included in a template with configuration. If you do not specify a shared secret for a template, Platform Manager uses the shared secret specified for the environment to which the source installation belongs. |
doOverwrite=true | false | Required. Whether to overwrite an existing template with the same alias. true - overwrite the existing template false (default) - do not overwrite the existing template |
{--input | -i} filename{.xml | .json}
| Required. An input file that contains the template metadata required for the template creation. For more information, see input. |
[command options] | Optional. The command allows all options supported by the Command Line Interface. For a description of the options, see Common Options. |
Usage Notes
The template XML metadata required for creating a template must follow the format below:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<templateMetadata>
<!-- template to create / apply -->
<alias>templateAlias</alias>
<!-- node alias to create from / apply to -->
<nodeAlias>nodeAlias</nodeAlias>
<!-- overwrite template, if exists -->
<overwriteTemplate>true</overwriteTemplate>
<!-- capture / install products -->
<productOption>
<!-- registered product repository Id: See below -->
<repositoryId>productRepositoryId</repositoryId>
<type>PRODUCTS</type>
<!-- install the latest version available in the above
repository -->
<useLatestVersion>false</useLatestVersion>
</productOption>
<!-- capture / install fixes -->
<fixesOption>
<!-- registered fix repository id: See below -->
<repositoryId>fixRepositoryId</repositoryId>
<!-- install the latest version available in the above
repository -->
<useLatestVersion>true</useLatestVersion>
<type>FIXES</type>
</fixesOption>
<!-- capture / copy files referenced from configurations -->
<filesOption>
<type>FILES</type>
</filesOption>
<!-- capture / apply configuration -->
<configurationOption>
<type>CONFIGURATION</type>
</configurationOption>
</templateMetadata>
When you make configuration changes externally to
Command Central, for example by configuring settings in
Integration Server Administrator, the changes may not be included in the created template. To ensure that external configuration changes are included in the template, run the
sagcc list configuration instances command with the refresh parameter set to
true.
To monitor the status of the job scheduled to create the template, specify the job ID returned by the create templates command in the
sagcc list jobmanager jobs command. The create templates command also provides a reference to the templates log that you can use to check the logs, using the
sagcc get diagnostics logs command.
A template that is created directly on
Platform Manager is not visible to
Command Central and cannot be applied to a different node. To apply a template created on
Platform Manager, you must manually export the template from the node and import it into
Command Central.
Example When Executing on Command Central
To create a template, based on the “templateMetadata.xml” file, on the
Command Central server with host name “rubicon” and port “8090”:
sagcc create templates snapshot --server http://rubicon:8090/cce
-p mypassword -i D:\templateMetadata.xml
To create a template with name “myTemplate” that contains the products and configuration installed on the
Platform Manager node with alias “prod-is”:
sagcc create templates snapshot alias=myTemplate nodeAlias=prod-is
options=PRODUCTS options=CONFIGURATION
To create a template with name “mySecureTemplate” that contains the products and configuration on the
Platform Manager node with alias “prod-is” and specify “mysecret” as the shared secret for the template:
sagcc create templates snapshot alias=mySecureTemplate
nodeAlias=prod-is options=PRODUCTS options=CONFIGURATION
sharedsecred=mysecret
To create a template with name “mySecureTemplate2” that contains the products and configuration on the
Platform Manager node with alias “prod-is” and use the default shared secret for the environment:
sagcc create templates snapshot alias=mySecureTemplate2
nodeAlias=prod-is options=PRODUCTS options=CONFIGURATION
Example When Executing on Platform Manager
To create a template, based on the “templateMetadata.xml” file, on the Platform Manager server with host name “rubicon” and port “8092”:
sagcc create templates --server http://rubicon:8092/spm -p mypassword
-i D:\templateMetadata.xml