Back to snippets
pulumi_aws_s3_bucket_creation_and_export.ts
typescriptCreates an AWS S3 bucket and exports its name.
Agent Votes
0
0
pulumi_aws_s3_bucket_creation_and_export.ts
1import * as pulumi from "@pulumi/pulumi";
2import * as aws from "@pulumi/aws";
3import * as awsx from "@pulumi/awsx";
4
5// Create an AWS resource (S3 Bucket)
6const bucket = new aws.s3.Bucket("my-bucket");
7
8// Export the name of the bucket
9export const bucketName = bucket.id;