From fbd0044ce9bfeb4dbc2bea825803c3777aa32231 Mon Sep 17 00:00:00 2001 From: Seth L <81644108+sethAmazon@users.noreply.github.com> Date: Thu, 10 Aug 2023 11:44:05 -0400 Subject: [PATCH] Upgrade EKS Version and Fix EKS EMF Log JSON (#329) --- terraform/eks/daemon/emf/main.tf | 2 +- terraform/eks/daemon/emf/variables.tf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/terraform/eks/daemon/emf/main.tf b/terraform/eks/daemon/emf/main.tf index e1bcfb305..28b8247de 100644 --- a/terraform/eks/daemon/emf/main.tf +++ b/terraform/eks/daemon/emf/main.tf @@ -337,7 +337,7 @@ resource "kubernetes_daemonset" "service" { command = [ "/bin/sh", "-c", - "while true; do CURRENT_TIME=\"$(date +%s%3N)\"; TIMESTAMP=\"$(($CURRENT_TIME *1000))\"; echo '{\"_aws\":{\"Timestamp\":'\"$${TIMESTAMP}\"',\"LogGroupName\":\"EMFEKSLogGroup\",\"CloudWatchMetrics\":[{\"Namespace\":\"EMFEKSNameSpace\",\"Dimensions\":[[\"Type\",\"ClusterName\"]],\"Metrics\":[{\"Name\":\"EMFCounter\",\"Unit\":\"Count\"}]}]},\"Type\":\"Counter\",\"EMFCounter\":5, \"ClusterName\": \"${aws_eks_cluster.this.name}\"}}' | socat -v -t 0 - UDP:0.0.0.0:25888; sleep 60; done" + "while true; do CURRENT_TIME=\"$(date +%s%3N)\"; TIMESTAMP=\"$(($CURRENT_TIME *1000))\"; echo '{\"_aws\":{\"Timestamp\":'\"$${TIMESTAMP}\"',\"LogGroupName\":\"EMFEKSLogGroup\",\"CloudWatchMetrics\":[{\"Namespace\":\"EMFEKSNameSpace\",\"Dimensions\":[[\"Type\",\"ClusterName\"]],\"Metrics\":[{\"Name\":\"EMFCounter\",\"Unit\":\"Count\"}]}]},\"Type\":\"Counter\",\"EMFCounter\":5, \"ClusterName\": \"${aws_eks_cluster.this.name}\"}' | socat -v -t 0 - UDP:0.0.0.0:25888; sleep 60; done" ] env { name = "HOST_IP" diff --git a/terraform/eks/daemon/emf/variables.tf b/terraform/eks/daemon/emf/variables.tf index 015d9b940..41afe484a 100644 --- a/terraform/eks/daemon/emf/variables.tf +++ b/terraform/eks/daemon/emf/variables.tf @@ -23,7 +23,7 @@ variable "cwagent_image_tag" { variable "k8s_version" { type = string - default = "1.24" + default = "1.27" } variable "ami_type" {