Create Terraform plugin configurations

2 minute readExtensibilityDeveloper productivity

Plugin configurations are sets of parameters that can be applied across some, or all, plugin procedures. They can reduce the repetition of common values, create predefined parameter sets, and securely store credentials. Each configuration is given a unique name that is entered in the designated parameter for the plugin procedures that use them. The following steps illustrate how to create a plugin configuration that can be used by one or more plugin procedures.

To create a plugin configuration:

  1. Navigate to DevOps Essentials  Plugin Management  Plugin configurations.

  2. Select Add plugin configuration to create a new configuration.

  3. In the New Configuration window, specify a Name for the configuration.

  4. Select the Project that the configuration belongs to.

  5. Optionally, add a Description for the configuration.

  6. Select the appropriate Plugin for the configuration.

  7. Configure the plugin configuration parameters.

  8. Select OK.

Depending on your plugin configuration and how you run procedures, the Input parameters  Configuration name field may behave differently in the CloudBees CD/RO UI. For more information, refer to Differences in plugin UI behavior.

Terraform plugin configuration parameters

Table 1. EC-Terraform plugin configuration parameters
Parameter Description

Name

Required. The unique name for the configuration.

Description

The configuration description.

Terraform client command

Required. Command that is used as a Terraform client. For example, /usr/bin/terraform, /my/custom-terraform, or sudo Terraform.

Terraform working directory

Working directory where commands are executed. If not set, the Commander workspace is used.

Terraform variables file location type

Variables file location. The options are: none, new file, or existing file.

Terraform variables file location

Absolute path to the Terraform variables file. This file is passed to Terraform using the --var-file= option.

Terraform variables file content

If you are using resource files that reference external variables, set these variables here. These variables are written to a temporary file and passed to Terraform using the --var-file= option.

Terraform workspace

Workspace of Terraform, to be used during Terraform operations. If it is not set, the default workspace is used. Terraform switches to this workspace before any applicable action. If this workspace does not exist, it is created.

Auth type

Mechanism to provide authentication data into the Terraform command call. To use the AWS driver, your Terraform playbook should contain an AWS {} block.

AWS credentials

AWS client ID and secret key to authorize the Terraform call. They are added to the command call as environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY.

AWS session token

AWS session token to use in the authentication, if required. It is added to the call as an environment variable, AWS_SESSION_TOKEN.

Debug level

This option sets the debug level for logs. If Info is selected, only a summary is displayed. If Debug is selected, debug information is displayed. If Trace is selected, all requests and responses are displayed.