From e5101bb99ad3bdf9853de91169e68de675df4636 Mon Sep 17 00:00:00 2001 From: Ganga Mahesh Siddem Date: Fri, 21 Aug 2020 10:33:40 -0700 Subject: [PATCH] [incubator/azuremonitor-containers] updates for agent release ciprod08072020 & win-ciprod08072020 (#23585) * updates for ciprod08072020 release Signed-off-by: Ganga Mahesh Siddem * switch to nodeselector for windows ds Signed-off-by: Ganga Mahesh Siddem --- incubator/azuremonitor-containers/Chart.yaml | 2 +- .../templates/omsagent-daemonset-windows.yaml | 13 ++++++++----- .../templates/omsagent-daemonset.yaml | 7 +++++++ .../templates/omsagent-deployment.yaml | 7 +++++++ .../templates/omsagent-rbac.yaml | 4 ++-- .../templates/omsagent-rs-configmap.yaml | 16 ++++++++++++++++ incubator/azuremonitor-containers/values.yaml | 17 +++-------------- 7 files changed, 44 insertions(+), 22 deletions(-) diff --git a/incubator/azuremonitor-containers/Chart.yaml b/incubator/azuremonitor-containers/Chart.yaml index 8a84692e72..2024941522 100644 --- a/incubator/azuremonitor-containers/Chart.yaml +++ b/incubator/azuremonitor-containers/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: 7.0.0-1 description: Helm chart for deploying Azure Monitor container monitoring agent in Kubernetes name: azuremonitor-containers -version: 2.7.3 +version: 2.7.4 kubeVersion: "^1.10.0-0" keywords: - monitoring diff --git a/incubator/azuremonitor-containers/templates/omsagent-daemonset-windows.yaml b/incubator/azuremonitor-containers/templates/omsagent-daemonset-windows.yaml index 2874a1e952..be952683d4 100644 --- a/incubator/azuremonitor-containers/templates/omsagent-daemonset-windows.yaml +++ b/incubator/azuremonitor-containers/templates/omsagent-daemonset-windows.yaml @@ -8,8 +8,8 @@ metadata: chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }} release: {{ .Release.Name }} heritage: {{ .Release.Service }} - component: oms-agent - tier: node + component: oms-agent-win + tier: node-win spec: updateStrategy: type: RollingUpdate @@ -25,6 +25,8 @@ spec: dockerProviderVersion: {{ .Values.omsagent.image.dockerProviderVersion }} schema-versions: "v1" spec: + nodeSelector: + beta.kubernetes.io/os: windows {{- if .Values.omsagent.rbac }} serviceAccountName: omsagent {{- end }} @@ -73,9 +75,6 @@ spec: - C:\opt\omsagentwindows\scripts\cmd\livenessProbe.cmd periodSeconds: 60 initialDelaySeconds: 180 - {{- with .Values.omsagent.daemonsetwindows.affinity }} - affinity: {{- toYaml . | nindent 8 }} - {{- end }} {{- with .Values.omsagent.tolerations }} tolerations: {{- toYaml . | nindent 8 }} {{- end }} @@ -93,4 +92,8 @@ spec: - name: omsagent-secret secret: secretName: omsagent-secret + - name: omsagent-adx-secret + secret: + secretName: omsagent-adx-secret + optional: true {{- end }} diff --git a/incubator/azuremonitor-containers/templates/omsagent-daemonset.yaml b/incubator/azuremonitor-containers/templates/omsagent-daemonset.yaml index e3f034f00a..d6d6171cdf 100644 --- a/incubator/azuremonitor-containers/templates/omsagent-daemonset.yaml +++ b/incubator/azuremonitor-containers/templates/omsagent-daemonset.yaml @@ -99,6 +99,9 @@ spec: - mountPath: {{ .Values.omsagent.logsettings.custommountpath }} name: custom-mount-path {{- end }} + - mountPath: /etc/config/settings/adx + name: omsagent-adx-secret + readOnly: true livenessProbe: exec: command: @@ -144,4 +147,8 @@ spec: hostPath: path: {{ .Values.omsagent.logsettings.custommountpath }} {{- end }} + - name: omsagent-adx-secret + secret: + secretName: omsagent-adx-secret + optional: true {{- end }} diff --git a/incubator/azuremonitor-containers/templates/omsagent-deployment.yaml b/incubator/azuremonitor-containers/templates/omsagent-deployment.yaml index 86ca7e9d33..6f8140eb6e 100644 --- a/incubator/azuremonitor-containers/templates/omsagent-deployment.yaml +++ b/incubator/azuremonitor-containers/templates/omsagent-deployment.yaml @@ -90,6 +90,9 @@ spec: - mountPath: {{ .Values.omsagent.logsettings.custommountpath }} name: custom-mount-path {{- end }} + - mountPath: /etc/config/settings/adx + name: omsagent-adx-secret + readOnly: true livenessProbe: exec: command: @@ -135,4 +138,8 @@ spec: hostPath: path: {{ .Values.omsagent.logsettings.custommountpath }} {{- end }} + - name: omsagent-adx-secret + secret: + secretName: omsagent-adx-secret + optional: true {{- end }} diff --git a/incubator/azuremonitor-containers/templates/omsagent-rbac.yaml b/incubator/azuremonitor-containers/templates/omsagent-rbac.yaml index bd095c2941..9903f41ffc 100644 --- a/incubator/azuremonitor-containers/templates/omsagent-rbac.yaml +++ b/incubator/azuremonitor-containers/templates/omsagent-rbac.yaml @@ -21,8 +21,8 @@ rules: - apiGroups: [""] resources: ["pods", "events", "nodes", "nodes/stats", "nodes/metrics", "nodes/spec", "nodes/proxy", "namespaces", "services"] verbs: ["list", "get", "watch"] -- apiGroups: ["apps", "extensions"] - resources: ["replicasets"] +- apiGroups: ["apps", "extensions", "autoscaling"] + resources: ["replicasets", "deployments", "horizontalpodautoscalers"] verbs: ["list"] - apiGroups: ["azmon.container.insights"] resources: ["healthstates"] diff --git a/incubator/azuremonitor-containers/templates/omsagent-rs-configmap.yaml b/incubator/azuremonitor-containers/templates/omsagent-rs-configmap.yaml index 9dda85441b..19e4454085 100644 --- a/incubator/azuremonitor-containers/templates/omsagent-rs-configmap.yaml +++ b/incubator/azuremonitor-containers/templates/omsagent-rs-configmap.yaml @@ -53,6 +53,22 @@ data: log_level debug + #Kubernetes object state - deployments + + type kubestatedeployments + tag oms.containerinsights.KubeStateDeployments + run_interval 60 + log_level debug + + + #Kubernetes object state - HPA + + type kubestatehpa + tag oms.containerinsights.KubeStateHpa + run_interval 60 + log_level debug + + type filter_inventory2mdm custom_metrics_azure_regions eastus,southcentralus,westcentralus,westus2,southeastasia,northeurope,westeurope,southafricanorth,centralus,northcentralus,eastus2,koreacentral,eastasia,centralindia,uksouth,canadacentral,francecentral,japaneast,australiaeast diff --git a/incubator/azuremonitor-containers/values.yaml b/incubator/azuremonitor-containers/values.yaml index 685c767bb0..bc6926bc61 100644 --- a/incubator/azuremonitor-containers/values.yaml +++ b/incubator/azuremonitor-containers/values.yaml @@ -7,10 +7,10 @@ omsagent: image: repo: "mcr.microsoft.com/azuremonitor/containerinsights/ciprod" - tag: "ciprod07152020" - tagWindows: "win-ciprod05262020-2" + tag: "ciprod08072020" + tagWindows: "win-ciprod08072020" pullPolicy: IfNotPresent - dockerProviderVersion: "10.0.0-3" + dockerProviderVersion: "10.0.0-4" agentVersion: "1.10.0.1" ## To get your workspace id and key do the following ## You can create a Azure Loganalytics workspace from portal.azure.com and get its ID & PRIMARY KEY from 'Advanced Settings' tab in the Ux. @@ -81,17 +81,6 @@ omsagent: operator: NotIn values: - master - daemonsetwindows: - affinity: - nodeAffinity: - requiredDuringSchedulingIgnoredDuringExecution: - nodeSelectorTerms: - - labelSelector: - matchExpressions: - - key: beta.kubernetes.io/os - operator: In - values: - - windows ## Configure resource requests and limits ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ ##