Adding optional name filter variable to be able to pin worker AMI to a release

This commit is contained in:
Max Williams
2019-03-05 14:54:46 +01:00
parent dcdf413bad
commit 95986471f0
3 changed files with 14 additions and 6 deletions

View File

@@ -18,11 +18,13 @@ data "aws_iam_policy_document" "workers_assume_role_policy" {
data "aws_ami" "eks_worker" {
filter {
name = "name"
values = ["amazon-eks-node-${var.cluster_version}-v*"]
values = ["amazon-eks-node-${var.cluster_version}-${var.worker_ami_name_filter}"]
}
most_recent = true
owners = ["602401143452"]
# Owner ID of AWS EKS team
owners = ["602401143452"]
}
data "aws_iam_policy_document" "cluster_assume_role_policy" {