Skip to content

Commit

Permalink
Merge pull request #19 from Richard-Mathie/patch-1
Browse files Browse the repository at this point in the history
fix route list count for terraform v0.11
  • Loading branch information
grem11n committed Jun 19, 2019
2 parents a8223d5 + b9654e8 commit 30d5d2b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ resource "aws_vpc_peering_connection_options" "accepter" {
###################
resource "aws_route" "this_routes_region" {
provider = "aws.this"
count = "${var.create_peering == 1 ? length(data.aws_route_tables.peer_vpc_rts.ids) : 0}"
count = "${var.create_peering == 1 ? length(data.aws_route_tables.this_vpc_rts.ids) : 0}"
route_table_id = "${data.aws_route_tables.this_vpc_rts.ids[count.index]}"
destination_cidr_block = "${data.aws_vpc.peer_vpc.cidr_block}"
vpc_peering_connection_id = "${var.peering_id == "" ? element(concat(aws_vpc_peering_connection.this.*.id, list("")), 0) : var.peering_id}"
Expand Down

0 comments on commit 30d5d2b

Please sign in to comment.