From d22d2994e60699abf0e15e12f6920d35793ae37f Mon Sep 17 00:00:00 2001 From: Angelos Mimidis Date: Tue, 14 Jun 2022 15:55:44 +0200 Subject: [PATCH 1/5] Allow using existing secret --- cluster-agent/templates/secret-cluster-agent.yaml | 4 +++- cluster-agent/values.yaml | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/cluster-agent/templates/secret-cluster-agent.yaml b/cluster-agent/templates/secret-cluster-agent.yaml index 9087c2f..d85d7c9 100644 --- a/cluster-agent/templates/secret-cluster-agent.yaml +++ b/cluster-agent/templates/secret-cluster-agent.yaml @@ -1,3 +1,4 @@ +{{- if not .Values.controllerInfo.existingSecret }} {{ $secret := (lookup "v1" "Secret" .Release.Namespace "cluster-agent-secret") }} {{ $annotations := dict "temp" "temp" }} {{ if $secret }} @@ -25,4 +26,5 @@ data: {{- end -}} {{- end -}} {{ end -}} -{{ end -}} \ No newline at end of file +{{ end -}} +{{- end }} \ No newline at end of file diff --git a/cluster-agent/values.yaml b/cluster-agent/values.yaml index 565936a..cf82fb8 100644 --- a/cluster-agent/values.yaml +++ b/cluster-agent/values.yaml @@ -6,6 +6,7 @@ installInfraViz: false # Docker images imageInfo: + existingSecret: false agentImage: docker.io/appdynamics/cluster-agent agentTag: 22.4.0 operatorImage: docker.io/appdynamics/cluster-agent-operator From 46ec98348bd3ef3f14d9024415f6763875cca84a Mon Sep 17 00:00:00 2001 From: Angelos Mimidis Date: Tue, 14 Jun 2022 15:58:17 +0200 Subject: [PATCH 2/5] Allow using existing secret --- cluster-agent/templates/secret-cluster-agent.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/cluster-agent/templates/secret-cluster-agent.yaml b/cluster-agent/templates/secret-cluster-agent.yaml index d85d7c9..bf3b863 100644 --- a/cluster-agent/templates/secret-cluster-agent.yaml +++ b/cluster-agent/templates/secret-cluster-agent.yaml @@ -1,5 +1,4 @@ {{- if not .Values.controllerInfo.existingSecret }} -{{ $secret := (lookup "v1" "Secret" .Release.Namespace "cluster-agent-secret") }} {{ $annotations := dict "temp" "temp" }} {{ if $secret }} {{ $annotations = $secret.metadata.annotations }} @@ -26,5 +25,4 @@ data: {{- end -}} {{- end -}} {{ end -}} -{{ end -}} {{- end }} \ No newline at end of file From 0e45bd9a3a55c68ddbcd88787ac07b93545e1ebc Mon Sep 17 00:00:00 2001 From: Angelos Mimidis Date: Tue, 14 Jun 2022 16:00:22 +0200 Subject: [PATCH 3/5] Allow using existing secret --- cluster-agent/values.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cluster-agent/values.yaml b/cluster-agent/values.yaml index cf82fb8..082f3ce 100644 --- a/cluster-agent/values.yaml +++ b/cluster-agent/values.yaml @@ -6,7 +6,6 @@ installInfraViz: false # Docker images imageInfo: - existingSecret: false agentImage: docker.io/appdynamics/cluster-agent agentTag: 22.4.0 operatorImage: docker.io/appdynamics/cluster-agent-operator @@ -21,6 +20,7 @@ imageInfo: # AppDynamics controller info (VALUES TO BE PROVIDED BY THE USER) controllerInfo: + existingSecret: false url: null account: null username: null From fe686b7a167e92a8e9d7572037c8d04af62eca34 Mon Sep 17 00:00:00 2001 From: Angelos Mimidis Date: Tue, 14 Jun 2022 16:04:41 +0200 Subject: [PATCH 4/5] Allow using existing secret --- cluster-agent/Chart.yaml | 5 ----- cluster-agent/templates/secret-cluster-agent.yaml | 2 ++ cluster-agent/values.yaml | 6 +++--- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/cluster-agent/Chart.yaml b/cluster-agent/Chart.yaml index a3a2cc3..10b53d9 100644 --- a/cluster-agent/Chart.yaml +++ b/cluster-agent/Chart.yaml @@ -9,11 +9,6 @@ version: 1.3.0 appVersion: 22.4.0 -dependencies: - - name: metrics-server - repository: https://kubernetes-sigs.github.io/metrics-server/ - version: 3.7.0 - condition: install.metrics-server maintainers: - name: AppDynamics diff --git a/cluster-agent/templates/secret-cluster-agent.yaml b/cluster-agent/templates/secret-cluster-agent.yaml index bf3b863..d85d7c9 100644 --- a/cluster-agent/templates/secret-cluster-agent.yaml +++ b/cluster-agent/templates/secret-cluster-agent.yaml @@ -1,4 +1,5 @@ {{- if not .Values.controllerInfo.existingSecret }} +{{ $secret := (lookup "v1" "Secret" .Release.Namespace "cluster-agent-secret") }} {{ $annotations := dict "temp" "temp" }} {{ if $secret }} {{ $annotations = $secret.metadata.annotations }} @@ -25,4 +26,5 @@ data: {{- end -}} {{- end -}} {{ end -}} +{{ end -}} {{- end }} \ No newline at end of file diff --git a/cluster-agent/values.yaml b/cluster-agent/values.yaml index 082f3ce..67a2958 100644 --- a/cluster-agent/values.yaml +++ b/cluster-agent/values.yaml @@ -21,11 +21,11 @@ imageInfo: # AppDynamics controller info (VALUES TO BE PROVIDED BY THE USER) controllerInfo: existingSecret: false - url: null - account: null + url: test + account: test username: null password: null - accessKey: null + accessKey: test globalAccount: null # To be provided when using machineAgent Window Image # SSL properties From dff559fd91206a2e60de61351c14f497a13014ea Mon Sep 17 00:00:00 2001 From: Angelos Mimidis Date: Tue, 14 Jun 2022 16:05:19 +0200 Subject: [PATCH 5/5] Allow using existing secret --- cluster-agent/Chart.yaml | 5 +++++ cluster-agent/values.yaml | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/cluster-agent/Chart.yaml b/cluster-agent/Chart.yaml index 10b53d9..a3a2cc3 100644 --- a/cluster-agent/Chart.yaml +++ b/cluster-agent/Chart.yaml @@ -9,6 +9,11 @@ version: 1.3.0 appVersion: 22.4.0 +dependencies: + - name: metrics-server + repository: https://kubernetes-sigs.github.io/metrics-server/ + version: 3.7.0 + condition: install.metrics-server maintainers: - name: AppDynamics diff --git a/cluster-agent/values.yaml b/cluster-agent/values.yaml index 67a2958..082f3ce 100644 --- a/cluster-agent/values.yaml +++ b/cluster-agent/values.yaml @@ -21,11 +21,11 @@ imageInfo: # AppDynamics controller info (VALUES TO BE PROVIDED BY THE USER) controllerInfo: existingSecret: false - url: test - account: test + url: null + account: null username: null password: null - accessKey: test + accessKey: null globalAccount: null # To be provided when using machineAgent Window Image # SSL properties