How to enable VPC Route Propagation

703 views
Skip to first unread message

Rajinder Singh

unread,
Jan 19, 2016, 2:11:55 PM1/19/16
to Terraform
Currently when we setup a new VPC we use terraform to provision all of our services.
We provision a VPC, subnets an routes.
We have to work with our networking team to setup VPC between our data center and our VPC. This step is manual.
Once VPC has been configured I want to enable route propagation in the route tables.

If I try to enable the route propagation by setting the propagating_vgws

resource "aws_route_table" "routetbl_private_1a" {
    vpc_id = "${aws_vpc.vpc.id}"
 propagating_vgws = ["${aws_vpn_gateway.vgw.id}}"]
  route {
        cidr_block = "${var.ip_all}"
        nat_gateway_id = "${aws_nat_gateway.ngw1.id}"
    }
    tags {
        Name = "${var.private_route_table_1a}"
  Environment = "${var.environment}"
    }
}

I get an error saying gateway not attached. Gateway is attached.
If I got to AWS console I can enable route propagation.


Has anyone successfully enabled route propagation on a route table yet?



Thanks

Rajinder Singh

unread,
Jan 25, 2016, 3:02:47 PM1/25/16
to Terraform
This capability is already available via aws_route 

In future route propagation may move from aws_route to aws_vpn_gateway https://github.com/hashicorp/terraform/issues/3424
Reply all
Reply to author
Forward
0 new messages