-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Requester-managed Interface VPC Endpoints #8396
Conversation
@@ -201,7 +205,70 @@ func resourceAwsVpcEndpointRead(d *schema.ResourceData, meta interface{}) error | |||
return nil | |||
} | |||
|
|||
return vpcEndpointAttributes(d, vpce.(*ec2.VpcEndpoint), conn) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace call to vpcEndpointAttributes()
with explicit setting of attributes (including new requester_managed
attribute).
d.SetId(aws.StringValue(vpce.VpcEndpointId)) | ||
|
||
return vpcEndpointAttributes(d, vpce, conn) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace call to vpcEndpointAttributes()
with explicit setting of attributes (including new requester_managed
attribute), see also https://github.com/terraform-providers/terraform-provider-aws/pull/8396/files#r277149439.
@@ -367,72 +434,6 @@ func vpcEndpointWaitUntilDeleted(conn *ec2.EC2, vpceId string, timeout time.Dura | |||
return err | |||
} | |||
|
|||
func vpcEndpointAttributes(d *schema.ResourceData, vpce *ec2.VpcEndpoint, conn *ec2.EC2) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -115,7 +119,39 @@ func resourceAwsVpcEndpointServiceRead(d *schema.ResourceData, meta interface{}) | |||
return nil | |||
} | |||
|
|||
return vpcEndpointServiceAttributes(d, svcCfg.(*ec2.ServiceConfiguration), conn) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace call to vpcEndpointServiceAttributes()
with explicit setting of attributes (including new manages_vpc_endpoints
attribute).
@@ -242,27 +278,6 @@ func waitForVpcEndpointServiceDeletion(conn *ec2.EC2, serviceID string) error { | |||
return err | |||
} | |||
|
|||
func vpcEndpointServiceAttributes(d *schema.ResourceData, svcCfg *ec2.ServiceConfiguration, conn *ec2.EC2) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replaced by direct setting of attributes:
Rebased to remove merge conflict. |
This has minor functionality updates, most of the changes are cleaning up the acceptance tests. |
Rebased to remove conflicts and also ran Acceptance tests: $ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSVpcEndpoint_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -parallel 4 -run=TestAccAWSVpcEndpoint_ -timeout 120m
=== RUN TestAccAWSVpcEndpoint_gatewayBasic
=== PAUSE TestAccAWSVpcEndpoint_gatewayBasic
=== RUN TestAccAWSVpcEndpoint_gatewayWithRouteTableAndPolicy
=== PAUSE TestAccAWSVpcEndpoint_gatewayWithRouteTableAndPolicy
=== RUN TestAccAWSVpcEndpoint_gatewayPolicy
=== PAUSE TestAccAWSVpcEndpoint_gatewayPolicy
=== RUN TestAccAWSVpcEndpoint_interfaceBasic
=== PAUSE TestAccAWSVpcEndpoint_interfaceBasic
=== RUN TestAccAWSVpcEndpoint_interfaceWithSubnetAndSecurityGroup
=== PAUSE TestAccAWSVpcEndpoint_interfaceWithSubnetAndSecurityGroup
=== RUN TestAccAWSVpcEndpoint_interfaceNonAWSService
=== PAUSE TestAccAWSVpcEndpoint_interfaceNonAWSService
=== RUN TestAccAWSVpcEndpoint_removed
=== PAUSE TestAccAWSVpcEndpoint_removed
=== CONT TestAccAWSVpcEndpoint_gatewayBasic
=== CONT TestAccAWSVpcEndpoint_interfaceBasic
=== CONT TestAccAWSVpcEndpoint_interfaceWithSubnetAndSecurityGroup
=== CONT TestAccAWSVpcEndpoint_removed
--- PASS: TestAccAWSVpcEndpoint_removed (37.77s)
=== CONT TestAccAWSVpcEndpoint_interfaceNonAWSService
--- PASS: TestAccAWSVpcEndpoint_gatewayBasic (44.91s)
=== CONT TestAccAWSVpcEndpoint_gatewayPolicy
--- PASS: TestAccAWSVpcEndpoint_interfaceBasic (72.89s)
=== CONT TestAccAWSVpcEndpoint_gatewayWithRouteTableAndPolicy
--- PASS: TestAccAWSVpcEndpoint_gatewayPolicy (74.24s)
--- PASS: TestAccAWSVpcEndpoint_gatewayWithRouteTableAndPolicy (81.93s)
--- PASS: TestAccAWSVpcEndpoint_interfaceNonAWSService (296.19s)
--- PASS: TestAccAWSVpcEndpoint_interfaceWithSubnetAndSecurityGroup (381.25s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 381.322s
$ make testacc TEST=./aws/ TESTARGS='-run=TestAccDataSourceAwsVpcEndpoint_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -parallel 20 -run=TestAccDataSourceAwsVpcEndpoint_ -timeout 120m
=== RUN TestAccDataSourceAwsVpcEndpoint_gatewayBasic
=== PAUSE TestAccDataSourceAwsVpcEndpoint_gatewayBasic
=== RUN TestAccDataSourceAwsVpcEndpoint_byId
=== PAUSE TestAccDataSourceAwsVpcEndpoint_byId
=== RUN TestAccDataSourceAwsVpcEndpoint_gatewayWithRouteTable
=== PAUSE TestAccDataSourceAwsVpcEndpoint_gatewayWithRouteTable
=== RUN TestAccDataSourceAwsVpcEndpoint_interface
=== PAUSE TestAccDataSourceAwsVpcEndpoint_interface
=== CONT TestAccDataSourceAwsVpcEndpoint_gatewayBasic
=== CONT TestAccDataSourceAwsVpcEndpoint_gatewayWithRouteTable
=== CONT TestAccDataSourceAwsVpcEndpoint_byId
=== CONT TestAccDataSourceAwsVpcEndpoint_interface
--- PASS: TestAccDataSourceAwsVpcEndpoint_byId (46.71s)
--- PASS: TestAccDataSourceAwsVpcEndpoint_gatewayBasic (48.44s)
--- PASS: TestAccDataSourceAwsVpcEndpoint_gatewayWithRouteTable (50.35s)
--- PASS: TestAccDataSourceAwsVpcEndpoint_interface (188.60s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 188.668s
$ make testacc TEST=./aws/ TESTARGS='-run=TestAccAWSVpcEndpointService_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -parallel 20 -run=TestAccAWSVpcEndpointService_ -timeout 120m
=== RUN TestAccAWSVpcEndpointService_basic
=== PAUSE TestAccAWSVpcEndpointService_basic
=== RUN TestAccAWSVpcEndpointService_removed
=== PAUSE TestAccAWSVpcEndpointService_removed
=== CONT TestAccAWSVpcEndpointService_basic
=== CONT TestAccAWSVpcEndpointService_removed
--- PASS: TestAccAWSVpcEndpointService_removed (270.09s)
--- PASS: TestAccAWSVpcEndpointService_basic (446.31s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 446.379s
$ make testacc TEST=./aws/ TESTARGS='-run=TestAccDataSourceAwsVpcEndpointService_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws/ -v -parallel 20 -run=TestAccDataSourceAwsVpcEndpointService_ -timeout 120m
=== RUN TestAccDataSourceAwsVpcEndpointService_gateway
=== PAUSE TestAccDataSourceAwsVpcEndpointService_gateway
=== RUN TestAccDataSourceAwsVpcEndpointService_interface
=== PAUSE TestAccDataSourceAwsVpcEndpointService_interface
=== RUN TestAccDataSourceAwsVpcEndpointService_custom
=== PAUSE TestAccDataSourceAwsVpcEndpointService_custom
=== CONT TestAccDataSourceAwsVpcEndpointService_gateway
=== CONT TestAccDataSourceAwsVpcEndpointService_interface
=== CONT TestAccDataSourceAwsVpcEndpointService_custom
--- PASS: TestAccDataSourceAwsVpcEndpointService_interface (17.79s)
--- PASS: TestAccDataSourceAwsVpcEndpointService_gateway (17.81s)
--- PASS: TestAccDataSourceAwsVpcEndpointService_custom (286.47s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 286.538s |
Merged as part of #8674 🚀 |
This has been released in version 2.16.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Fixes #8386.
Release note for CHANGELOG:
Acceptance tests:
d/aws_vpc_endpoint_service
r/aws_vpc_endpoint_service
d/aws_vpc_endpoint
r/aws_vpc_endpoint