Skip to content

Commit

Permalink
Only override vpc endpoint type on govcloud if empty.
Browse files Browse the repository at this point in the history
Once govcloud implements multiple vpc endpoint types, we should stop
forcing the endpoint type to gateway.

h/t @wjwoodson
jmcarp committed Mar 9, 2018
1 parent d0ef740 commit 7a106be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion aws/resource_aws_vpc_endpoint.go
Original file line number Diff line number Diff line change
@@ -347,7 +347,7 @@ func vpcEndpointAttributes(d *schema.ResourceData, vpce *ec2.VpcEndpoint, meta i

serviceName := aws.StringValue(vpce.ServiceName)
d.Set("service_name", serviceName)
if meta.(*AWSClient).IsGovCloud() {
if meta.(*AWSClient).IsGovCloud() && aws.StringValue(vpce.VpcEndpointType) == "" {
d.Set("vpc_endpoint_type", ec2.VpcEndpointTypeGateway)
} else {
d.Set("vpc_endpoint_type", vpce.VpcEndpointType)

0 comments on commit 7a106be

Please sign in to comment.