CloudCenter-Defined Parameters

Overview

Automated parameters are defined in the CloudCenter platform and contain the following characteristics:

  • Values provided by the CloudCenter platform.

  • Designed to cover unknown, dynamically generated values or system-dependent values.

  • Reusable in application profiles to automate jobs without writing extensive scripts (examples include timestamp, dynamically-generated IP address, private IP address, IP address of a tier, environment variables, automation policy parameters, number of nodes in a cluster, deployment name, and so forth).

Using CloudCenter-Defined Parameters

To use a system-defined parameter, follow this procedure:

  1. Use the parameter name to reference this parameter inside a configuration script or configuration file as a macro using the CloudCenter platform convention. For example:

    • Parameter name: XYZ_TIER_IP

    • Macro reference for this parameter: %XYZ_TIER_IP%

  2. Reference the macro inside the Application Profile.

The following sections list all parameters, macros, and environment variables defined for the CloudCenter platform for use in CloudCenter deployments.

Standard IP Address Replacement Parameters

These parameters are available at the application level. Some parameters are specific to some application profiles as identified in the Description column.

Use the same case and format (UPPER_CASE).

CloudCenter-Defined
Parameters

Description

%XYZ_TIER_IP%

  • Private IP address of a custom tier. XYZ is custom tier name
  • If the tier name is Custom1, then macro name will be %Custom1_TIER_IP%

%DB_TIER_IP%

  • Private IP address of the database tier.
  • The tier name must be Database

%NOSQL_TIER_IP%

Private IP address of NoSQL Database tier

%MB_TIER_IP%

Private IP address of Message BUS

$CliqrTier_{Tiername}_IP

Private IP of tier named XYZ

%BC_TIER_IP%

Private IP address of Backend Cache

Input Parameters for Scripts

These parameters are available at the application level. Some parameters are specific to some application profiles as identified in the Description column.

Use the same case and format (UPPER_CASE)

See VM Name Config for the pre-defined macros that you can use for the CliQr Macro Replacement Option.

CloudCenter-Defined
Parameters

Description

%OUTPUT_DIR%

Path for output directory:
/shared/output

%JOB_NAME%Name of the deployment
%USER_NAME%Name of the user deploying the application
%FIRST_NAME%First name of the user deploying the application
%LAST_NAME%Last name of the user deploying the application
%EMAIL_ADDRESS%Email address of the user deploying the application

%USER_EXTERNAL_ID% or

%userExternalId%

External ID of the user deploying the application (if using SSO)

Both versions of this macro are the same – the %userExternalId% macro is replaced by the user's external ID in the URL for webservice (see Using Parameters > Parameter Type for additional details on webservice)

%DEPLOYMENT_ENV%

Name of the deployment environment

%DEP_ENV_NAME%Name of the Puppet or Chef environment

%TIME%

Time stamp string in yyyyMMddHHmmss format

%TASK_INDEX%

  • Task index starting from 1
  • Applies to Batch Compute Application Profiles

%NODE_INDEX%

  • Node index starting from 1
  • Applies to: 
    • Cluster Compute Application Profiles
    • Parallel Execution Application Profile

%HOST_IPS%

  • Host IP address list delimit by comma 
  • Applies to Cluster Compute Application Profiles

%NUM_CPU%

Number of CPUs on the application VM

$VM_NODE_INDEX

This is an additional macro to create VMs using a sequential number for each VM that is newly created. For example, if you use this macro to launch an N-Tier app with 3 nodes:

  • The VM_NODE_INDEX is set as 1, 2, and 3.
  • If you remove Node 2 and add one more node, the VM_NODE_INDEX is set as1, 3, 4, and 5.
  • For Tiers with only one node the VM_NODE_INDEX is set to 1.

This macro is exported as part of userenv file. To consume this macro, add $VM_NODE_INDEX to your scripts and source the userenv(/usr/local/osmosix/etc/userenv) file use the variables as part of your scripts.

SSH Keys Parameters

The parameters listed in the following table are available when using SSH keys.

CloudCenter-Defined Parameters

Description

sshUserNameThe SSH user name for the current cloud VM
sshKeyThe SSH private key for the current cloud VM
sshPublicKeyThe SSH public key for the current cloud VM

Automation Policy Parameters

These parameters are only applicable when defining custom action policies and are not available at the application level.

Use the same case and format (camelCase)

CloudCenter-Defined Parameters

Description

%myEmail%

User's email address

%firstName%

User first name

%vendorName%

Tenant name to send notifications, if any

%jobName%

Name of the deployment job

%jobUrl%

The URL for the deployment

%jobType%

Type of deployment job (for example, benchmark)

%appName%

Name of the application

%owner%

Owner of the deployment job

%status%

Current status of the job (for example, Running)

%cloudName%

Name of the cloud (for example, Amazon US East (Virginia))

%paramCloudType%Identifies the cloud in which the node is launched

RDS Service Parameters

When defining the RDS OOB service, be sure to pass the values for the VPC ID and DB Subnet Group at deployment time. The CloudCenter platform requires these values to provision the RDS instance. See External Service for additional context. The following table identifies a list of parameters that are required when configuring an RDS service. These following RDS-specific deployment parameters are also available on the CloudCenter platform.

Parameter

Description

vpcIdRequired. The VPC ID with which the RDS Instance is associated, its the same VPC ID of the DBSubnetGroup – a Security Group will be created using this VPC ID.
dbSubnetGroupRequired. The DB Subnet Group with which the RDS Instance is associated.
cliqrIsPublicAccessibleRequired. The RDS service to be toggled to true (default) or false so you can control public accessibility.
cliqrRdsEngineVersionYou can customize the RDS service using this parameter. For the RDS MySQL OOB service, the default CloudCenter version is listed as CloudCenter 5.6.35. You can customize this version by adding a custom, deploy parameter with this name and pass the value during deployment.
cliqrStorageTypeYou can customize the RDS service using this parameter. For RDS MySQL OOB service, the default storage type used by the CloudCenter platform is Magnetic (standard storage). You can customize this storage type by adding a custom, deploy parameter with this name and pass the value as “gp2” for general purpose SSD or “io1” for provisioned IOPS. See Multiple Volumes for additional context.
portYou can customize the RDS service using this parameter. For RDS MySQL OOB service, the default port used by the CloudCenter platform is 3306. You can customize this port by adding a custom, deploy parameter with this name and pass the value as desired.
cidrYou can customize the RDS service using this parameter. When creating an RDS security group, the default port used by the CloudCenter platform opens to CIDR 0.0.0.0/0. You can customize the CIDR by adding a custom, deploy parameter with this name and pass the value as desired.
sgidYou can customize the RDS service using this parameter. For RDS MySQL OOB service, the CloudCenter platform creates a new security group with security rules mentioned as port and/or cidr parameters, You can customize the sgid by adding a custom, deploy parameter with this name and pass the value of security group so that RDS Instance will be launched using the specific security group. See Security and Firewall Rules for additional context.

Kubernetes Container Service Parameters

The CloudCenter platform supports variables to reference various Kubernetes network parameters as listed in the following table. Users can reference the namespace of the tier, and various network parameters for a specific service name in the namespace.

In the following table:

  • <ServiceName> is the string entered by the user in the Port Name field in the Network Services section of the topology modeler for a container tier.

  • ServiceName is the string generated by the CloudCenter CCO at deploy time and injected into the Kubernetes cluster using Port Name, Job ID, and a 6-character hexadecimal random number generator.

The following network related parameters are available from a Kubernetes Container Service:

Output valueOutput formatVariable syntax

Applicable service types

Cluster IP Service Name List

<ServiceName1>, <ServiceName1>, . . .CliqrTier_<tier_name>_ClusterIP_ServiceNameClusterIP
NodePort Service Name List<ServiceName1>, <ServiceName1>, . . .CliqrTier_<tier_name>_NodePort_ServiceNameNodePort
LoadBalancer Service Name List

<ServiceName1>, <ServiceName1>, . . .

CliqrTier_<tier_name>_LoadBalancer_ServiceNameLoadBalancer
ClusterIP Internal Endpoint List<ServiceName1>:<port_no>, <ServiceName2>:<port_no>, . . .CliqrTier_<tier_name>_ClusterIP_EndpointClusterIP
NodePort Internal Endpoint List<ServiceName1>:<service_port_no>, <ServiceName1>:<node_port_no>,
<ServiceName2>:<service_port_no>, <ServiceName2>:<node_port_no>,
. . .
CliqrTier_<tier_name>_NodePort_EndpointNodePort
LoadBalancer Internal Endpoint List<ServiceName1>:<port_no>, <ServiceName2>:<port_no>, . . .CliqrTier_<tier_name>_LoadBalancer_InternalEndpointLoadBalancer
External Endpoint List<ip_address1>:<port_no>, <ip_address2>:<port_no>, . . .CliqrTier_<tier_name>_LoadBalancer_ExternalEndpointLoadBalancer
Public IP List<ip_address1>, <ip_address2>, . . .CliqrTier_<tier_name>_PUBLIC_IPLoadBalancer
Cluster IP List<ip_address1>, <ip_address2>, . . .Any of these:
CliqrTier_<tier_name>_ClusterIP
CliqrTier_<tier_name>_PRIVATE_IP
CliqrTier_<tier_name>_IP
All
Pod IP List<ip_address1>, <ip_address2>, . . .CliqrTier_<tier_name>_PodIPAll
NamespacestringCliqrTier_<tier_name>_NamespaceAll
Cluster IP<ip_address>

Any of the following:
CliqrTier_<tier_name>_<service_name>
CliqrTier_<tier_name>_<service_name>_ClusterIP
CliqrTier_<tier_name>_<service_name>_PRIVATE_IP
CliqrTier_<tier_name>_<service_name>_IP

All
Internal Endpoint

For ClusterIP and LoadBalancer service types:
<ServiceName>:<port_no>
For NodePort service type:
<ServiceName>:<service_port_no>, <ServiceName>:<node_port_no>

CliqrTier_<tier_name>_<service_name>_EndpointAll
External Endpoint<ip_address>:<port_no>CliqrTier_<tier_name>_<service_name>_ExternalEndpointLoadBalancer only
Public IP<ip_address>CliqrTier_<tier_name>_<service_name>_PUBLIC_IPLoadBalancer only
Service Name<service_name>-<job_id>-<rnd_no>CliqrTier_<tier_name>_<service_name>_ServiceNameAll

These parameters may be referenced within the Deployment Parameters section of the Topology Modeler when the application profile contains a container service tier. See Container Service for an example.

If only one network service for a particular network service type is defined for a container-based tier in the Topology Modeler, then the corresponding service name and IP parameters will contain single values. If multiple network services of a particular network service type are defined for a tier in the Topology Modeler, then the corresponding service name and IP parameters will each contain a comma separated string representing the values for each of the network services of that type. 

These parameters may be referenced within the Deployment Parameters section of the Topology Modeler when the application profile contains a container service tier. See Container Service for an example.

If only one network service for a particular network service type is defined for a container-based tier in the Topology Modeler, then the corresponding service name and IP parameters will contain single values. If multiple network services of a particular network service type are defined for a tier in the Topology Modeler, then the corresponding service name and IP parameters will each contain a comma separated string representing the values for each of the network services of that type. 

Docker Container Environment Variables

The variable listed in the following table are specific to Docker containers.

CloudCenter-Defined Variables

Description
Cloud_Setting_CloudFamilyThe cloud family of the region in the CloudCenter platform.
Cloud_Setting_cloudThe region name, for example: Amazon-us-west-2.
CliqrTier_NameListThe names list of all tiers in the application.
CliqrCloud_RegionEndPointThe region endpoint, example: ec2.us-west-2.amazonaws.com.
CliqrDepEnvIdThe Deployment environment ID created by the CloudCenter platform.
cliqrAppNameThe application Name in the CloudCenter platform.
launchUserNameThe launch username in the CloudCenter platform., for example: cliqradmin
cliqrAppTypeThe type of application in the CloudCenter platform, for example: n-tier
CliqrDepEnvNameThe deployment environment name n the CloudCenter platform

Docker Custom Service Variables

Right before your script is executed in a custom Docker service, CloudCenter supplies all the following application-specific parameters as environment variables.

CloudCenter-Defined Variables

Description

$region

Identifies the region information in the environment variables for External Services.
$CloudFamily

Identifies the cloud family in the environment variables for External Services.

cliqrContainerExecuteScriptTimeoutLimits the Docker container from running forever if an external service falls into an infinite loop. See External Service > Script Timer.

VM-Based Environment Variables

These variables are also part of the application and password parameters list.

CloudCenter-Defined Variables

Description

cliqrNodeId
  • The Node ID of the VM for which the external initialization script is executed.
  • Used for the external, pre-init, Deployment Lifecycle Script.

cliqrNodeHostname
  • The hostname of the VM for which the external initialization script is  executed.
  • Used for the external, pre-init, Deployment Lifecycle Script.

cliqrNodePublicIpThe Public IP of the VM for which the external initialization script is executed.
cliqrNodePrivateIpThe Private IP of the VM for which the external initialization script is executed.
$cliqrWindowsPassword

N-Tier Environment Variables

The parameters listed in the following table are available at the application level. Some parameters are specific to some application profiles as identified in the Description column.

These values cannot be overridden!

Use the same case and format (InitCaps).


CloudCenter-Defined Variables

Description

$CliqrDependents

Comma separated list of connected top tiers name of the tier

$CliqrDependencies

Comma separated list of top tier names connected to bottom tier names

$CliqrDepEnvName

Deployment environment name

$CliqrDepEnvId
  • Helpful on the restore side of the migration as it is available from the source (where the backup is being run).
  • For example: To backup, use <path>/$CliqrDepEnvId 
$CliqrDeploymentId
  • Current deployment ID that ties the pre- and post-migration operations together for scripting purposes (backups and so forth)
  • For example: To backup, use <path>/$CliqrDeploymentId 
$migrateFromDepId
  • Only available for post-migrate operations and points to the previous deployment ID.
  • For example: To restore, <path>/$migrateFromDepId
CliqrTier_<job_name>_PUBLIC_IPPublic IP address for the tier. This parameter is also available as a Cluster-Based Environment Variable (Cluster Compute Application Profiles).

$CliqrTag_{Tagname}

Job tags defined during run time with value

ScaleType
  • The value can be either ScaleUp or ScaleDown.
  • Displays the type of scaling on the tier with the name $CliqrTier_scalingTierName)
CliqrTier_scalingTierName
  • The tier name on which the scaling operation occurred.
CliqrTier_{$CliqrTier_scalingTierName}_scaleUpPublicIps
  • ScaleUp parameter.
  • The public IPs of the VMs that are scaled up on the tier with the name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleUpNodeIds
  • ScaleUp parameter.
  • The nodeIds of the nodes that are scaled up on the tier with name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleUpPrivateIps
  • ScaleUp parameter.
  • The private IPs of the nodes that are scaled up on the tier with name $CliqrTier_scalingTierName.

CliqrTier_{$CliqrTier_scalingTierName}_scaleUpHostnames

  • ScaleUp parameter.
  • The hostnames of the nodes that are scaled up on the tier with name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleDownPublicIps
  • ScaleDown parameter.
  • The public IPs of the nodes that are scaled down on the tier with name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleDownNodeIds
  • ScaleDown parameter.
  • The nodeIds of the nodes that are scaled down on the tier with name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleDownPrivateIps
  • ScaleDown parameter.
  • The private IPs of the nodes that are scaled down on the tier with name $CliqrTier_scalingTierName.
CliqrTier_{$CliqrTier_scalingTierName}_scaleDownHostnames
  • ScaleDown parameter.
  • The hostnames of the nodes that are scaled down on the tier with name $CliqrTier_scalingTierName.
CLIQR_EXECUTE_SCRIPTThe execution command/script for the current Docker container run.
externalServiceBundleThe path/URL to the external service bundle (configured on the CCO Wizard Properties)
actionTypeThe action type of the current external service action, the possible values: SCRIPT or URL or CMD
serviceNameThe name of the External Service.
CUSTOM_REPO_URLThe CloudCenter custom bundle store  URL (configured on the CCO Wizard Properties)

Cluster-Based Environment Variables

The variables listed in the following table are available in Cluster Compute Application Profiles.

CloudCenter-Defined Variables

Description

CliqrTier_<job_name>_IPPrivate IP address for the tier
CliqrTier_<job_name>_PUBLIC_IPPublic IP address for the tier. This parameter is also available for N-tier deployments
CliqrTier_<job_name>_HOSTNAMEHostname for the tier

Lifecycle actions have access to a separate list of environmental variables that are associated with the resources to which they are mapped. You can use these variables in a script, default value, or body fields modeled as part of the action, and are passed on as environment variables to the VM. See Actions Library > Lifecycle Actions for additional context. The following table lists the CloudCenter-defined environment variables for Lifecycle Actions.

CloudCenter-Defined VariablesDescription
Job Variables for Lifecycle Actions
JOB ID: %jobId%The internal ID for a deployed run
JOB NAME %jobName%The name of the deployed run
JOB URL: %jobUrl%The deployment URL
JOB TYPE: %jobType%The deployment type
JOB OWNER: %jobOwner%The owner of the Deployment
Application Profile Variables for Lifecycle Actions
APP ID: %appId%The Application Profile ID
APP NAME: %appName%The Application Profile Name
APP OWNER: %appOwner%The owner of the Application
APP OWNER ID: %appOwnerId%The ID of the Application Owner
Service Variables for Lifecycle Actions
SERVICE ID: %serviceId%The Service ID
SERVICE NAME: %serviceName%The Service Name
SERVICE OWNER: %serviceOwner%The Service Owner
SERVICE OWNER ID: %serviceOwnerId%The ID of the Service Owner
Cloud Region Variables for Lifecycle Actions
CLOUD ID: %cloudId%The Cloud ID
CLOUD NAME: %cloudName%The Cloud Name
CLOUD OWNER: %cloudOwnerId%The ID of the Cloud Owner

Parameters as Environment Variables

The parameters listed in the following table are available as environment variables. Some parameters are specific to some application profiles as identified in the Description column.

Use the same case and format (InitCaps or camelCase)

CloudCenter-Defined Variables

Description

$UseBatchTaskList

  • Applies to Batch Execution Application Profile.
  • When set to:
    • 1 = command is read from a task list file
    • 0 = command is an execution command line

$NumTasks

  • Only applicable when UseBatchTaskList=0.
  • Represents the number of tasks to be performed (number of times to repeat a series of execution commands).
  • Applies to Batch Compute Application Profiles

$numClusterNodes

Number of nodes in the tier

$minClusterSize

Minimum number of nodes in a cluster

$maxClusterSize

Maximum number of nodes in a cluster

$minAppClusterSize

Maximum number of nodes for java container-based tiers

  • The userenv Utility File

Tier-based firewall information is available in a VM's userenv file as well as the environment for external initialization scripts as evident in the following examples:

  • Example 1
    firewall={
       "id":null,
       "name":"cliqr-firewall-58E00D70D552698B4355B1F2135F0229",
       "description":"Cliqr user firewall",
       "rules":[
          {
             "protocol":"tcp",
             "fromPort":22,
             "toPort":22,
             "sourceIPRanges":["0.0.0.0/0"],
             "sourceGroups":null,
             "cloudId":null,
             "serviceName":null
          }
       ]
    }
  • Example 2
    firewall={
       "id":null,
       "name":"cliqr-firewall_C1_VMW2_CentOS_1_6438",
       "description":"Cliqr user firewall",
       "rules":[
          {
             "protocol":"tcp",
             "fromPort":22,
             "toPort":22,
             "sourceIPRanges":["0.0.0.0/0"],
             "sourceGroups":null,
             "cloudId":null,
             "serviceName":null
          },
          {
             "protocol":"tcp",
             "fromPort":80,
             "toPort":80,
             "sourceIPRanges":["1.1.1.1/0"],
             "sourceGroups":null,
             "cloudId":null,
             "serviceName":null
          },
          {
             "protocol":"tcp",
             "fromPort":1,
             "toPort":65535,
             "sourceIPRanges":[
                "TIER_WebServer"
             ],
             "sourceGroups":null,
             "cloudId":null,
             "serviceName":null
          }
       ]
    }

    Back to:Parameters and Macro

  • No labels
© 2017-2019 Cisco Systems, Inc. All rights reserved