Commit da00c05e authored by Daisuke Fujita's avatar Daisuke Fujita

Modify tag format

parent 398309f0
......@@ -14,9 +14,11 @@ resource "aws_autoscaling_group" "<%= module_name_of(group) %>" {
vpc_zone_identifier = <%= vpc_zone_identifier_of(group).inspect %>
<%- end -%>
tags {
tag {
<% group.tags.each do |tag| -%>
"<%= tag.key %>" = "<%= tag.value %>"
key = "<%= tag.key %>"
value = "<%= tag.value %>"
propagate_at_launch = <%= tag.propagate_at_launch.to_s %>
<% end -%>
}
}
......
......@@ -44,7 +44,13 @@ module Terraforming
vpc_zone_identifier: "",
enabled_metrics: [],
tags: [
{ key: "Name", value: "hoge" }
{
resource_id: "hoge",
resource_type: "auto-scaling-group",
key: "foo",
value: "bar",
propagate_at_launch: true,
}
],
termination_policies: ["Default"],
},
......@@ -104,8 +110,10 @@ resource "aws_autoscaling_group" "hoge" {
min_size = 1
name = "hoge"
tags {
"Name" = "hoge"
tag {
key = "foo"
value = "bar"
propagate_at_launch = true
}
}
......@@ -119,7 +127,7 @@ resource "aws_autoscaling_group" "fuga" {
name = "fuga"
vpc_zone_identifier = ["subnet-1234abcd", "subnet-5678efgh"]
tags {
tag {
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment