Skip to content
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

aws_vpc_endpoint type mismatch for ec2 service_name #2695

Closed
georgesvachulay opened this issue Dec 18, 2017 · 2 comments
Closed

aws_vpc_endpoint type mismatch for ec2 service_name #2695

georgesvachulay opened this issue Dec 18, 2017 · 2 comments
Labels
enhancement Requests to existing resources that expand the functionality or scope. new-resource Introduces a new resource. service/ec2 Issues and PRs that pertain to the ec2 service.
Milestone

Comments

@georgesvachulay
Copy link

Terraform Version

Terraform v0.11.1
+ provider.aws v1.5.0
+ provider.template v1.0.0

Terraform Configuration Files

# AWS service endpoint (to use CLI internally) for EC2
resource "aws_vpc_endpoint" "internal-ec2" {
  vpc_id          = "${aws_vpc.ps-eu.id}"
  service_name    = "com.amazonaws.eu-west-2.ec2"
  route_table_ids = ["${aws_vpc.ps-eu.main_route_table_id}"]
}

Debug Output

Crash Output

Error: Error applying plan:

1 error(s) occurred:

* aws_vpc_endpoint.internal-ec2: 1 error(s) occurred:

* aws_vpc_endpoint.internal-ec2: Error creating VPC Endpoint: InvalidParameter: Endpoint type (Gateway) does not match service type (Interface).
        status code: 400, request id: adca118c-c4bd-4814-92fc-c0bc3c2af51e

Terraform does not automatically rollback in the face of errors.
Instead, your Terraform state file has been partially updated with
any resources that successfully completed. Please address the error
above and apply again to incrementally change your infrastructure.

Expected Behavior

successful run

Actual Behavior

type mismatch

Steps to Reproduce

Important Factoids

S3 and DynamoDB endpoints are Gateway types, but ec2, servicecatalog, ssm, etc. types are Interface types. It's likely that the class expects all input to be a gateway, however that's not the case anymore (instead of a gateway it should be creating an interface for the ec2 service_name)

References

hashicorp/terraform#16941

@ewbankkit
Copy link
Contributor

This is addressed in #2515.

@jen20 jen20 added the bug Addresses a defect in current functionality. label Dec 29, 2017
@radeksimko radeksimko added enhancement Requests to existing resources that expand the functionality or scope. new-resource Introduces a new resource. service/ec2 Issues and PRs that pertain to the ec2 service. and removed bug Addresses a defect in current functionality. labels Jan 22, 2018
@bflad bflad added this to the v1.9.0 milestone Jul 2, 2018
@bflad bflad closed this as completed Jul 2, 2018
@ghost
Copy link

ghost commented Apr 4, 2020

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!

@ghost ghost locked and limited conversation to collaborators Apr 4, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Requests to existing resources that expand the functionality or scope. new-resource Introduces a new resource. service/ec2 Issues and PRs that pertain to the ec2 service.
Projects
None yet
Development

No branches or pull requests

5 participants