provider/aws: detach VPN gateway with proper ID

This commit is contained in:
Mitchell Hashimoto 2015-05-06 09:44:50 -07:00
parent 47a45a68a6
commit b184e283b9
2 changed files with 1 additions and 5 deletions

View File

@ -218,7 +218,7 @@ func resourceAwsVpnGatewayDetach(d *schema.ResourceData, meta interface{}) error
wait := true wait := true
_, err := conn.DetachVPNGateway(&ec2.DetachVPNGatewayInput{ _, err := conn.DetachVPNGateway(&ec2.DetachVPNGatewayInput{
VPNGatewayID: aws.String(d.Id()), VPNGatewayID: aws.String(d.Id()),
VPCID: aws.String(d.Get("vpc_id").(string)), VPCID: aws.String(vpcID.(string)),
}) })
if err != nil { if err != nil {
ec2err, ok := err.(aws.APIError) ec2err, ok := err.(aws.APIError)

View File

@ -192,10 +192,6 @@ resource "aws_vpn_gateway" "foo" {
` `
const testAccVpnGatewayConfigChangeVPC = ` const testAccVpnGatewayConfigChangeVPC = `
resource "aws_vpc" "foo" {
cidr_block = "10.1.0.0/16"
}
resource "aws_vpc" "bar" { resource "aws_vpc" "bar" {
cidr_block = "10.2.0.0/16" cidr_block = "10.2.0.0/16"
} }