Create the SSH custom activity
- UpdatedAug 3, 2023
- 3 minutes to read
- Vancouver
- Cloud Management
The Vancouver release is no longer supported. As such, the product documentation and release notes are provided for informational purposes only, and will not be updated.
Create an SSH custom activity so you can use it in your workflow.
Before you begin
Procedure
- Navigate to All > Admin Portal > Workflows > Workflow Editor.
- Click the Custom tab, then click + (plus sign) to create a new custom activity.
-
From the list of types of activities, choose SSH.
- When the Activity Designer opens with the General tab displayed, enter a unique name for the activity and then click Continue.
-
In the Inputs tab, add the input variables with the following steps, then click Continue:
- In the Input table, click the + in a circle to create a new input variable.
-
Click to the right of ABC in the Name column, and type the input name.
Inputs vary according to the object to be impacted. Here, we're creating an activity to stop a VM, so the inputs reflect the values needed to accomplish that action.
The Type and Mandatory columns populate automatically according to input you enter.
-
Create a new input object for each input in the following table, then click Continue:
Input variable Type Mandatory Host String No Command String No CredentialTag String No
-
On the Execution Command tab, perform the following:
-
Click and drag the input variables from the left to the template fields at the right.
This step creates the expressions that will be used.
- Check the Must Sudo box so that you can later log in to the virtual server.
-
Click Continue.
-
Click and drag the input variables from the left to the template fields at the right.
-
On the Outputs tab, add the output variables with the following steps:
- In the Output table, click the + in a circle to create a new output variable.
-
Click to the right of ABC in the Name column, and type the output name.
The output variables reflect the possible outcomes when the workflow attempts to SSH to the VM. The Type column populates automatically.
Outputs Type error String output String - Click and drag the error variable to the Variable name field in the Parsing rules table.
- In the Parsing rule for error dialog, in the Parsing source drop-down, select the appropriate source; in this case, executionResult.errorMessages.
-
Repeat for the output variable, selecting executionResult.output as the Parsing source, then click Submit.
-
Click Continue.
Conditions are optional.
- Click Save, then click Publish to make the activity available to use in the workflow.
What to do next