Learn how to use the storage bucket resource to retain session recordings for compliance. Understand storage bucket attributes and how scopes affect storage.
At this time, the only supported storage for storage buckets is AWS S3.
In AWS S3, a storage bucket contains the bucket name, region, and optional prefix, as well as any credentials needed to access the bucket, such as the secret key.
The AWS S3 storage bucket can use static or dynamic credentials.
You can configure static credentials using an access key and secret key or dynamic credentials using the AWS [`AssumeRole` API](https://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRole).
- `disable_credential_rotation` - (Optional for static credentials, Required for dynamic credentials) If set to `true`, credential rotation is not performed.
Note that this attribute is required, if you use dynamic credentials.
- `role_arn` - (Optional) The ARN (Amazon Resource Name) role that is attached to the EC2 instance that the self-managed worker runs on.
The Role ARN is required if the AWS S3 bucket is configured to use dynamic credentials using `AssumeRole`.
- `role_external_id` - (Optional) A required value if you delegate third party access to your AWS resources.
You can configure this value if your AWS S3 bucket is configured to use dynamic credentials.
For more information, refer to the AWS documentation for [How to use an external ID when granting access to your AWS resources to a third party](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html).
- `role_session_name`: (Optional) A unique identifier for the AWS session.
You can use this value to control how IAM principals and applications name their role sesions when they assume an IAM role.
By providing a session name, you enable tracking session actions in AWS CloudTrail logs.
You can configure this value if your AWS S3 bucket is configured to use dynamic credentials.
For more information, refer to the AWS documentation for [Logging IAM and AWS STS API calls with AWS CloudTrail](https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html).
- `role_tags`: (Optional) An object with key-value pair attributes that is passed when you assume an IAM role.
For more information, refer to the AWS documentation for [Passing session tags in AWS STS](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html).
### Secrets
AWS S3 buckets can have the following secrets:
- `access_key_id` - (Optional) The access key ID for the IAM user to use with this storage bucket.
Access keys are required if the AWS S3 bucket is configured to use static credentials.
- `secret_access_key` - (Optional) The secret access key for the IAM user to use with this storage bucket.
Secret access keys are required if the AWS S3 bucket is configured to use static credentials.