I am trying to upload a file to S3 Bucket using multi-region access point and Terraform. However, Terraform says The S3 arn should have a region but, multi-region access point does not define any region.
resource "aws_s3_bucket_object" "examplebucket_object" {
key = "test.jpg"
bucket = "arn:aws:s3::111111111111:accesspoint/aaaaaaaaaaaaa.mrap"
source = "test.jpg"
}
Error: Error uploading object to S3 bucket
(arn:aws:s3::111111111111:accesspoint/aaaaaaaaaaaaa.mrap): InvalidARNError: invalid
ARN
caused by: invalid Amazon s3 ARN, region not set,
arn:aws:s3::111111111111:accesspoint/aaaaaaaaaaaaa.mrap
with aws_s3_bucket_object.examplebucket_object,
on main.tf line 1, in resource "aws_s3_bucket_object" "examplebucket_object":
1: resource "aws_s3_bucket_object" "examplebucket_object" {
I tried the same with aws cli. it worked well.
Anyone has any idea?