Resource: awsLightsailBucketAccessKey
Provides a lightsail bucket access key. This is a set of credentials that allow API requests to be made to the lightsail bucket.
Example Usage
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
new aws.lightsailBucket.LightsailBucket(this, "test", {
bundleId: "small_1_0",
name: "mytestbucket",
});
const awsLightsailBucketAccessKeyAccessKeyTest =
new aws.lightsailBucketAccessKeyAccessKey.LightsailBucketAccessKeyAccessKey(
this,
"test_1",
{
bucket_name: "${aws_lightsail_bucket_access_key.test.id}",
}
);
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
awsLightsailBucketAccessKeyAccessKeyTest.overrideLogicalId("test");
Argument Reference
The following arguments are supported:
bucketName
- (Required) The name of the bucket that the new access key will belong to, and grant access to.
Attributes Reference
In addition to all arguments above, the following attributes are exported:
id
- A combination of attributes separated by a,
to create a unique id:bucketName
,accessKeyId
accessKeyId
- The ID of the access key.createdAt
- The timestamp when the access key was created.secretAccessKey
- The secret access key used to sign requests. This attribute is not available for imported resources. Note that this will be written to the state file.status
- The status of the access key.
Import
awsLightsailBucketAccessKey
can be imported by using the id
attribute, e.g.,