ParameterArgs

data class ParameterArgs(val allowedPattern: Output<String>? = null, val arn: Output<String>? = null, val dataType: Output<String>? = null, val description: Output<String>? = null, val insecureValue: Output<String>? = null, val keyId: Output<String>? = null, val name: Output<String>? = null, val overwrite: Output<Boolean>? = null, val tags: Output<Map<String, String>>? = null, val tier: Output<String>? = null, val type: Output<Either<String, ParameterType>>? = null, val value: Output<String>? = null) : ConvertibleToJava<ParameterArgs>

Provides an SSM Parameter resource.

Note: overwrite also makes it possible to overwrite an existing SSM Parameter that's not created by the provider before.

Example Usage

Basic example

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ssm.Parameter;
import com.pulumi.aws.ssm.ParameterArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var foo = new Parameter("foo", ParameterArgs.builder()
.type("String")
.value("bar")
.build());
}
}

Encrypted string using default SSM KMS key

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.rds.Instance;
import com.pulumi.aws.rds.InstanceArgs;
import com.pulumi.aws.ssm.Parameter;
import com.pulumi.aws.ssm.ParameterArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var default_ = new Instance("default", InstanceArgs.builder()
.allocatedStorage(10)
.storageType("gp2")
.engine("mysql")
.engineVersion("5.7.16")
.instanceClass("db.t2.micro")
.name("mydb")
.username("foo")
.password(var_.database_master_password())
.dbSubnetGroupName("my_database_subnet_group")
.parameterGroupName("default.mysql5.7")
.build());
var secret = new Parameter("secret", ParameterArgs.builder()
.description("The parameter description")
.type("SecureString")
.value(var_.database_master_password())
.tags(Map.of("environment", "production"))
.build());
}
}

Import

SSM Parameters can be imported using the parameter store name, e.g.,

$ pulumi import aws:ssm/parameter:Parameter my_param /my_path/my_paramname

Constructors

Link copied to clipboard
constructor(allowedPattern: Output<String>? = null, arn: Output<String>? = null, dataType: Output<String>? = null, description: Output<String>? = null, insecureValue: Output<String>? = null, keyId: Output<String>? = null, name: Output<String>? = null, overwrite: Output<Boolean>? = null, tags: Output<Map<String, String>>? = null, tier: Output<String>? = null, type: Output<Either<String, ParameterType>>? = null, value: Output<String>? = null)

Properties

Link copied to clipboard
val allowedPattern: Output<String>? = null

Regular expression used to validate the parameter value.

Link copied to clipboard
val arn: Output<String>? = null

ARN of the parameter.

Link copied to clipboard
val dataType: Output<String>? = null

Data type of the parameter. Valid values: text, aws:ssm:integration and aws:ec2:image for AMI format, see the Native parameter support for Amazon Machine Image IDs.

Link copied to clipboard
val description: Output<String>? = null

Description of the parameter.

Link copied to clipboard
val insecureValue: Output<String>? = null

Value of the parameter. Use caution: This value is never marked as sensitive in the preview. This argument is not valid with a type of SecureString.

Link copied to clipboard
val keyId: Output<String>? = null

KMS key ID or ARN for encrypting a SecureString.

Link copied to clipboard
val name: Output<String>? = null

Name of the parameter. If the name contains a path (e.g., any forward slashes (/)), it must be fully qualified with a leading forward slash (/). For additional requirements and constraints, see the AWS SSM User Guide.

Link copied to clipboard
val overwrite: Output<Boolean>? = null

Overwrite an existing parameter. If not specified, will default to false if the resource has not been created by this provider to avoid overwrite of existing resource and will default to true otherwise.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

Map of tags to assign to the object. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Link copied to clipboard
val tier: Output<String>? = null

Parameter tier to assign to the parameter. If not specified, will use the default parameter tier for the region. Valid tiers are Standard, Advanced, and Intelligent-Tiering. Downgrading an Advanced tier parameter to Standard will recreate the resource. For more information on parameter tiers, see the AWS SSM Parameter tier comparison and guide.

Link copied to clipboard
val type: Output<Either<String, ParameterType>>? = null

Type of the parameter. Valid types are String, StringList and SecureString. The following arguments are optional:

Link copied to clipboard
val value: Output<String>? = null

Value of the parameter. This value is always marked as sensitive in the plan output, regardless of type.

Functions

Link copied to clipboard
open override fun toJava(): ParameterArgs