Class CfnProject.EnvironmentVariableProperty.Builder
java.lang.Object
software.amazon.awscdk.services.codebuild.CfnProject.EnvironmentVariableProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnProject.EnvironmentVariableProperty>
- Enclosing interface:
CfnProject.EnvironmentVariableProperty
@Stability(Stable)
public static final class CfnProject.EnvironmentVariableProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnProject.EnvironmentVariableProperty>
A builder for
CfnProject.EnvironmentVariableProperty
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.Sets the value ofCfnProject.EnvironmentVariableProperty.getName()
Sets the value ofCfnProject.EnvironmentVariableProperty.getType()
Sets the value ofCfnProject.EnvironmentVariableProperty.getValue()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
name
Sets the value ofCfnProject.EnvironmentVariableProperty.getName()
- Parameters:
name
- The name or key of the environment variable. This parameter is required.- Returns:
this
-
value
Sets the value ofCfnProject.EnvironmentVariableProperty.getValue()
- Parameters:
value
- The value of the environment variable. This parameter is required.We strongly discourage the use of
PLAINTEXT
environment variables to store sensitive values, especially AWS secret key IDs and secret access keys.PLAINTEXT
environment variables can be displayed in plain text using the AWS CodeBuild console and the AWS CLI . For sensitive values, we recommend you use an environment variable of typePARAMETER_STORE
orSECRETS_MANAGER
.- Returns:
this
-
type
Sets the value ofCfnProject.EnvironmentVariableProperty.getType()
- Parameters:
type
- The type of environment variable. Valid values include:.PARAMETER_STORE
: An environment variable stored in Systems Manager Parameter Store. For environment variables of this type, specify the name of the parameter as thevalue
of the EnvironmentVariable. The parameter value will be substituted for the name at runtime. You can also define Parameter Store environment variables in the buildspec. To learn how to do so, see env/parameter-store in the AWS CodeBuild User Guide .PLAINTEXT
: An environment variable in plain text format. This is the default value.SECRETS_MANAGER
: An environment variable stored in AWS Secrets Manager . For environment variables of this type, specify the name of the secret as thevalue
of the EnvironmentVariable. The secret value will be substituted for the name at runtime. You can also define AWS Secrets Manager environment variables in the buildspec. To learn how to do so, see env/secrets-manager in the AWS CodeBuild User Guide .
- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnProject.EnvironmentVariableProperty>
- Returns:
- a new instance of
CfnProject.EnvironmentVariableProperty
- Throws:
NullPointerException
- if any required attribute was not provided
-