mirror of
https://github.com/ysoftdevs/terraform-aws-eks.git
synced 2026-03-23 09:51:04 +01:00
Better examples, PR template changes, general tidy up (#375)
* adding 3 examples * removing old example * updating PR template * fix this typo * update after renaming default example * add missing launch_template_mixed stuff to aws_auth * fix 2 examples with public subnets * update changelog for new minor release
This commit is contained in:
11
aws_auth.tf
11
aws_auth.tf
@@ -33,6 +33,15 @@ EOS
|
||||
|
||||
data "aws_caller_identity" "current" {}
|
||||
|
||||
data "template_file" "launch_template_mixed_worker_role_arns" {
|
||||
count = "${var.worker_group_launch_template_mixed_count}"
|
||||
template = "${file("${path.module}/templates/worker-role.tpl")}"
|
||||
|
||||
vars {
|
||||
worker_role_arn = "arn:aws:iam::${data.aws_caller_identity.current.account_id}:role/${element(coalescelist(aws_iam_instance_profile.workers_launch_template_mixed.*.role, data.aws_iam_instance_profile.custom_worker_group_launch_template_mixed_iam_instance_profile.*.role_name), count.index)}"
|
||||
}
|
||||
}
|
||||
|
||||
data "template_file" "launch_template_worker_role_arns" {
|
||||
count = "${var.worker_group_launch_template_count}"
|
||||
template = "${file("${path.module}/templates/worker-role.tpl")}"
|
||||
@@ -55,7 +64,7 @@ data "template_file" "config_map_aws_auth" {
|
||||
template = "${file("${path.module}/templates/config-map-aws-auth.yaml.tpl")}"
|
||||
|
||||
vars {
|
||||
worker_role_arn = "${join("", distinct(concat(data.template_file.launch_template_worker_role_arns.*.rendered, data.template_file.worker_role_arns.*.rendered)))}"
|
||||
worker_role_arn = "${join("", distinct(concat(data.template_file.launch_template_worker_role_arns.*.rendered, data.template_file.worker_role_arns.*.rendered, data.template_file.launch_template_mixed_worker_role_arns.*.rendered)))}"
|
||||
map_users = "${join("", data.template_file.map_users.*.rendered)}"
|
||||
map_roles = "${join("", data.template_file.map_roles.*.rendered)}"
|
||||
map_accounts = "${join("", data.template_file.map_accounts.*.rendered)}"
|
||||
|
||||
Reference in New Issue
Block a user