Cloud Formation Stack
Deploys an Application CloudFormation Stack from the Serverless Application Repository.
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.AwsFunctions;
import com.pulumi.aws.inputs.GetRegionArgs;
import com.pulumi.aws.serverlessrepository.CloudFormationStack;
import com.pulumi.aws.serverlessrepository.CloudFormationStackArgs;
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) {
final var currentPartition = AwsFunctions.getPartition();
final var currentRegion = AwsFunctions.getRegion();
var postgres_rotator = new CloudFormationStack("postgres-rotator", CloudFormationStackArgs.builder()
.applicationId("arn:aws:serverlessrepo:us-east-1:297356227824:applications/SecretsManagerRDSPostgreSQLRotationSingleUser")
.capabilities(
"CAPABILITY_IAM",
"CAPABILITY_RESOURCE_POLICY")
.parameters(Map.ofEntries(
Map.entry("endpoint", String.format("secretsmanager.%s.%s", currentRegion.applyValue(getRegionResult -> getRegionResult.name()),currentPartition.applyValue(getPartitionResult -> getPartitionResult.dnsSuffix()))),
Map.entry("functionName", "func-postgres-rotator")
))
.build());
}
}
Content copied to clipboard
Import
Serverless Application Repository Stack can be imported using the CloudFormation Stack name (with or without the serverlessrepo-
prefix) or the CloudFormation Stack ID, e.g.,
$ pulumi import aws:serverlessrepository/cloudFormationStack:CloudFormationStack example serverlessrepo-postgres-rotator
Content copied to clipboard
Properties
Link copied to clipboard
The ARN of the application from the Serverless Application Repository.
Link copied to clipboard
A list of capabilities. Valid values are CAPABILITY_IAM
, CAPABILITY_NAMED_IAM
, CAPABILITY_RESOURCE_POLICY
, or CAPABILITY_AUTO_EXPAND
Link copied to clipboard
A map of Parameter structures that specify input parameters for the stack.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
The version of the application to deploy. If not supplied, deploys the latest version.