Parameters tab of Helm charts / Templates activity
You can set the parameter values for template and helm charts from the Composition tab > template / helm chart activity > Parameters tab.
Procedure
- Select the activity in the Composition tab. The input parameters are displayed along with their name and value on the right-hand side.
- You can use the Search Parameters to filter and search for a parameter.
-
You can edit directly to hardcode the value of a parameter, link the value to a parameter or create a new parameter:
- To edit the value of a parameter:
- Mouse-hover the parameter and click the Input Parameters link.
- Update the value.
- Click Save.
-
Link the parameter value:
- Click the Input Parameters link and click Link Parameters to map a parameter. The Link Parameter page is displayed.
-
In the Link Parameter page, click to select an option from the left-hand side. The following menu options are available on the left-side for mapping the parameter values:
Note: Not all options are available for a parameter. It varies based on the activities used in the service.
- Input Parameters - The Input Parameters menu option on the left-hand side lists all the parameters that are available in the Input Parameters section of the main Parameters tab of a service.
-
Shared Parameters
Note: If you link the attribute of a shared parameter, then an input parameter is automatically created. During service deployment, select the dataobject for the datatype. The data attribute value of the selected dataobject is used during provisioning.
- Templates
- Helm Charts
- Ansible: If the Ansible tower connection in configured, all Ansible job templates are listed here.
-
Business Process Manager - If you have configured a Business Process Manager connection, then all Business Process Manager activities are available for association.
-
Map values with the parameter:
-
Click to select a option on the left-hand side. The values displayed on the right-hand view changes based on the option you select on the left-hand side and the activities you have used in your service workflow.
Notes: For example, if there are two templates A and B placed in sequence in the Provision Action of the Composition tab, then parameters of both the templates are available in the Activity Parameters section of the Parameters tab. If you want to link a parameter of template B, then a list of all parameters of the template A and shared parameters are available for association. If your service involves Business Process Manager activities and helm charts, then they are also available for linking. For the very first activity, template A, you can only link input parameters and shared parameters.
- On the right-hand side, expand as required and mouse-hover the parameters to see a plus icon.
- Click the plus icon to select it. A green tick mark indicates your selection and also the Value is refreshed. You can also use the Search Parameter to filter and find a parameter.
-
-
Create a new parameter:
- Click the Link Parameter. The Link Parameter page is displayed.
- In the Link Parameter page, click Create tab. You can create only a new parameter whose type exists in the template activity. For example, a template has string, boolean, and map parameter types. If you want to create a new parameter of type counter, you must go to the main Parameters tab. To work with the main Parameters tab, see Working with the Parameters tab.
-
Select End-User Permissions.
The three different types of permissions are as follows:
-
Invisible - During parameter creation, enter a value for the Default Value. This parameter is not visible while creating an instance of the service.
Note: For the Invisible parameter, if you enter incorrect data in the default value field, then the Service instance deployment of the content run time fails.
-
Read-only - During parameter creation, enter or select the following values:
- Parameter Type - Select a type. It determines the type of parameter. The available parameter types are string, password, list, boolean, counter, map, connection, and shared parameters.
- Display Name - The label or display name of the parameter.
- Description - The description appears as a tooltip when the customer orders this service.
- Default Value - The default value of the parameter. When you create the service instance, this parameter is visible to you in read-only format.
- For list data type, you can click Add New to add a list of values.
- For map data type, you can click Add New to add a list of Key Value pairs. Click cross icon to delete a value record.
- For password data type, toggle between Show and Hide to view or hide the password characters.
-
Read and Write - When you create a service instance, you can make changes to the values that were defined during creation. Enter or select the following values for Read and Write permission:
- Parameter Type - Select a type. It determines the type of parameter. The available parameters are string, stringlist, password, list, boolean, counter, and map.
- Value Required - Determines whether a value is required for the parameter.
- Specify Options - For string data type, you can select this option for a drop-down list of string values.
- Display Name - The label or display name of the parameter.
- Description - The description appears as a tooltip when the customer orders this service.
- Validation Rule - The validation rule is a non mandatory field that is available only if you select "string" or "password" value in Parameter Type drop-down list. Validation Rule (regex) provides an ability to the service composer to restrict the values of an input parameter. If regex is provided during service composition, then the value of the string input parameter must satisfy the regex criteria during service deployment. For example, (\w+?@\w+?\x2E.+).
-
Validation Rule Description - Validation Rule Description (regexdesc) provides information about the validation rule. For example, "Enter a valid email address". Here, (\w+?@\w+?\x2E.+) is the regular expression for an email address. If you try to enter “abc.xyz.com” as the value for string input parameters, then service deployment fails due to invalid email address.
Note: For more information about regex, see regexlib.com
.
- Default Value - If you select, Specify Options, then enter values for Label and Value pair fields. Select a record to mark it as default value. You can click the cross mark icon to delete a value record.
-
-
Click Save to save the changes.
Tip: You can refactor some of the repetitive parameter values into data type and data objects. If you have numerous template parameters and you want to hardcode the values or reuse it multiple times, then you can take advantage of the shared parameter. When you define the template parameters during service composition, you can associate a Data Type that includes the repetitive attributes and select the appropriate Data Object with hard-coded values during deployment. For example, you create a "vSphere Managed Inventory Definitions" data type that contains all vSphere VMware related attributes, such as dns suffix, data center, data store and so on. You can create a "CAM VC2 data center" data object that is associated to "vSphere Managed Inventory Definitions" Data Type and hard code all the values. If you want to have another set of similar values to use during deployment, you can create a copy of this "CAM VC2 data center" and update values as required and save it with a different name. During deployment, you can select the appropriate Data Object. For the actual procedure to create a copy of a Data Object, see Duplicate Data Object.
- To edit the value of a parameter:
- The output parameters are displayed at the end along with their names in read-only mode. You can also view the output parameters in the Source Code tab at the same level as
template_params.
Notes:
- For more information, see Input output mapping for templates and helm charts.
- If you remove the mapping of service parameters in the Composition tab > Parameters tab of the template activity, it does not delete it from the main Parameters tab > Service Parameters section of the service and is also available while you create a service instance. If you do not want to see it while you create a service instance, you must delete it exclusively from the main Parameters tab > Service Parameters section.