Sha256: 0ccb27cc8e8bc3b64c60ca709ebfe9d3b973bc104bb8960d1d56d22bbad45737

Contents?: true

Size: 833 Bytes

Versions: 3

Compression:

Stored size: 833 Bytes

Contents

<% route_tables.each do |route_table| -%>
resource "aws_route_table" "<%= module_name_of(route_table) %>" {
    vpc_id     = "<%= route_table.vpc_id %>"

<% routes_of(route_table).each do |route| -%>
    route {
        cidr_block = "<%= route.destination_cidr_block %>"
<% if route.gateway_id -%>
        gateway_id = "<%= route.gateway_id %>"
<% end -%>
<% if route.instance_id -%>
        instance_id = "<%= route.instance_id %>"
<% end -%>
<% if route.vpc_peering_connection_id -%>
        vpc_peering_connection_id = "<%= route.vpc_peering_connection_id %>"
<% end -%>
<% if route.network_interface_id -%>
        network_interface_id = "<%= route.network_interface_id %>"
<% end -%>
    }

<% end -%>
    tags {
<% route_table.tags.each do |tag| -%>
        "<%= tag.key %>" = "<%= tag.value %>"
<% end -%>
    }
}

<% end -%>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
terraforming-0.6.1 lib/terraforming/template/tf/route_table.erb
terraforming-0.6.0 lib/terraforming/template/tf/route_table.erb
terraforming-0.5.0 lib/terraforming/template/tf/route_table.erb