From c7bce1832edd7adf1a7686c0c8fd3810c88c577f Mon Sep 17 00:00:00 2001 From: shuheiktgw Date: Wed, 24 Feb 2021 07:46:01 +0900 Subject: [PATCH 1/2] aws_vpc_endpoint: Correct the ARN account id --- aws/data_source_aws_vpc_endpoint.go | 2 +- aws/resource_aws_vpc_endpoint.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/aws/data_source_aws_vpc_endpoint.go b/aws/data_source_aws_vpc_endpoint.go index e3d778e807da..3dee22f20b01 100644 --- a/aws/data_source_aws_vpc_endpoint.go +++ b/aws/data_source_aws_vpc_endpoint.go @@ -163,7 +163,7 @@ func dataSourceAwsVpcEndpointRead(d *schema.ResourceData, meta interface{}) erro Partition: meta.(*AWSClient).partition, Service: ec2.ServiceName, Region: meta.(*AWSClient).region, - AccountID: meta.(*AWSClient).accountid, + AccountID: aws.StringValue(vpce.OwnerId), Resource: fmt.Sprintf("vpc-endpoint/%s", d.Id()), }.String() d.Set("arn", arn) diff --git a/aws/resource_aws_vpc_endpoint.go b/aws/resource_aws_vpc_endpoint.go index 6cb8862a3d58..7bb0b47d3c78 100644 --- a/aws/resource_aws_vpc_endpoint.go +++ b/aws/resource_aws_vpc_endpoint.go @@ -228,7 +228,7 @@ func resourceAwsVpcEndpointRead(d *schema.ResourceData, meta interface{}) error Partition: meta.(*AWSClient).partition, Service: ec2.ServiceName, Region: meta.(*AWSClient).region, - AccountID: meta.(*AWSClient).accountid, + AccountID: aws.StringValue(vpce.OwnerId), Resource: fmt.Sprintf("vpc-endpoint/%s", d.Id()), }.String() d.Set("arn", arn) From 508d1cc195912aa2b7ccfb526362da5508442fc9 Mon Sep 17 00:00:00 2001 From: shuheiktgw Date: Thu, 25 Feb 2021 06:07:58 +0900 Subject: [PATCH 2/2] Remove aws_vpc_endpoint from the document --- website/docs/index.html.markdown | 2 -- 1 file changed, 2 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index ee1f9fed757d..667cd6de295f 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -333,8 +333,6 @@ for more information about connecting to alternate AWS endpoints or AWS compatib - [`aws_vpc_dhcp_options` resource](/docs/providers/aws/r/vpc_dhcp_options.html) - [`aws_vpc_endpoint_service` data source](/docs/providers/aws/d/vpc_endpoint_service.html) - [`aws_vpc_endpoint_service` resource](/docs/providers/aws/r/vpc_endpoint_service.html) - - [`aws_vpc_endpoint` data source](/docs/providers/aws/d/vpc_endpoint.html) - - [`aws_vpc_endpoint` resource](/docs/providers/aws/r/vpc_endpoint.html) - [`aws_vpc` data source](/docs/providers/aws/d/vpc.html) - [`aws_vpc` resource](/docs/providers/aws/r/vpc.html) - [`aws_vpn_connection` resource](/docs/providers/aws/r/vpn_connection.html)