Connects an S3 bucket to an application. This capability first configures the IAM role policy to grant the application access to the S3 bucket. This module grants full access to the S3 bucket. Finally, the bucket name and connection url are injected into the application via ENV variables.
Anytime you need to connect your application to an S3 bucket.
First, create an S3 bucket datastore in Nullstone. You may need to contact someone with privileges to create the S3 bucket for you.
Once the datastore is created, use this capability to connect the S3 bucket to your application.
After connected and your application infrastructure is launched, use the injected ENV variable S3_BUCKET_URL to access the S3 bucket in your code.
The S3_BUCKET_NAME ENV variable is also injected in case you need that value by itself.
| Name | Description |
|---|---|
s3_bucket |
The s3 bucket that this capability is granting access to. |
| Name | Description |
|---|---|
S3_BUCKET_NAME |
The name of the s3 bucket that we are connecting to. |
S3_BUCKET_URL |
The bucket as an s3://<bucket> URI, the form AWS SDKs, the CLI, and filesystem libraries accept. |
S3_BUCKET_ARN |
The ARN of the s3 bucket. |
S3_BUCKET_REGION |
The region the s3 bucket lives in. |
S3_URL |
Deprecated, use S3_BUCKET_URL. Emits the bucket ARN, not a URL. |