AWS Amazon S3 Cached Iscsi Volume
This page shows how to write Terraform for Amazon S3 Cached Iscsi Volume and write them securely.
aws_storagegateway_cached_iscsi_volume (Terraform)
The Cached Iscsi Volume in Amazon S3 can be configured in Terraform with the resource name aws_storagegateway_cached_iscsi_volume. The following sections describe 1 example of how to use the resource and its parameters.
Example Usage from GitHub
resource "aws_storagegateway_cached_iscsi_volume" "this" {
gateway_arn = var.gateway_arn
kms_encrypted = var.kms_encrypted
kms_key = var.kms_key
network_interface_id = var.network_interface_id
snapshot_id = var.snapshot_id
Parameters
-
arnoptional computed - string -
chap_enabledoptional computed - bool -
gateway_arnrequired - string -
idoptional computed - string -
kms_encryptedoptional - bool -
kms_keyoptional - string -
lun_numberoptional computed - number -
network_interface_idrequired - string -
network_interface_portoptional computed - number -
snapshot_idoptional - string -
source_volume_arnoptional - string -
tagsoptional - map from string to string -
target_arnoptional computed - string -
target_namerequired - string -
volume_arnoptional computed - string -
volume_idoptional computed - string -
volume_size_in_bytesrequired - number
Explanation in Terraform Registry
Manages an AWS Storage Gateway cached iSCSI volume.
NOTE: The gateway must have cache added (e.g., via the
aws_storagegateway_cacheresource) before creating volumes otherwise the Storage Gateway API will return an error. NOTE: The gateway must have an upload buffer added (e.g., via theaws_storagegateway_upload_bufferresource) before the volume is operational to clients, however the Storage Gateway API will allow volume creation without error in that case and return volume status asUPLOAD BUFFER NOT CONFIGURED.
Tips: Best Practices for The Other AWS Amazon S3 Resources
In addition to the aws_s3_bucket_public_access_block, AWS Amazon S3 has the other resources that should be configured for security reasons. Please check some examples of those resources and precautions.
aws_s3_bucket_public_access_block
Ensure S3 bucket-level Public Access Block restricts public bucket policies
It is better to enable S3 bucket-level Public Access Block if you don't need public buckets.
aws_s3_bucket
Ensure S3 bucket access policy is well configured
It is better to configure the S3 bucket access policy properly to limit it unless explicitly required.
CloudFormation Example
CloudFormation code does not have the related resource.
Frequently asked questions
What is AWS Amazon S3 Cached Iscsi Volume?
AWS Amazon S3 Cached Iscsi Volume is a resource for Amazon S3 of Amazon Web Service. Settings can be wrote in Terraform.
Where can I find the example code for the AWS Amazon S3 Cached Iscsi Volume?
For Terraform, the niveklabs/aws source code example is useful. See the Terraform Example section for further details.