Supply count for map_accounts, map_roles and map_users (#205)

* Added map_roles_count and user_roles_count (#1)

* Update readme for new vars

* updated tests to include count

* fix syntax error

* updated changelog

* Added map_accounts_count variable for consistency

* Fix counts in example and user latest terraform-docs to generate readme
This commit is contained in:
Diego Rodriguez
2018-12-13 06:50:46 -08:00
committed by Max Williams
parent 37f18c17c9
commit 1822a677dc
6 changed files with 60 additions and 17 deletions

View File

@@ -42,7 +42,7 @@ data "template_file" "config_map_aws_auth" {
}
data "template_file" "map_users" {
count = "${length(var.map_users)}"
count = "${var.map_users_count}"
template = "${file("${path.module}/templates/config-map-aws-auth-map_users.yaml.tpl")}"
vars {
@@ -53,7 +53,7 @@ data "template_file" "map_users" {
}
data "template_file" "map_roles" {
count = "${length(var.map_roles)}"
count = "${var.map_roles_count}"
template = "${file("${path.module}/templates/config-map-aws-auth-map_roles.yaml.tpl")}"
vars {
@@ -64,7 +64,7 @@ data "template_file" "map_roles" {
}
data "template_file" "map_accounts" {
count = "${length(var.map_accounts)}"
count = "${var.map_accounts_count}"
template = "${file("${path.module}/templates/config-map-aws-auth-map_accounts.yaml.tpl")}"
vars {