@@ -118,10 +118,10 @@ Determine argocd argocd repo server port
118118
119119
120120{ {/*
121- Determine argocd repoServer url
121+ Determine argocd repoServer url
122122*/} }
123123{ {- define " codefresh-gitops-runtime.argocd.reposerver.url" -} }
124- { {- $argoCDValues := (get .Values " argo-cd" ) } }
124+ { {- $argoCDValues := (get .Values " argo-cd" ) } }
125125{ {- if and (index .Values " argo-cd" " enabled" ) } }
126126 { {- $serviceName := include " codefresh-gitops-runtime.argocd.reposerver.servicename" . } }
127127 { {- $port := include " codefresh-gitops-runtime.argocd.reposerver.serviceport" . } }
@@ -149,8 +149,12 @@ Determine argocd servicename. Must be called with chart root context
149149Determine rollouts name
150150*/} }
151151{ {- define " codefresh-gitops-runtime.argo-rollouts.name" -} }
152- { {/* For now use template from rollouts chart until better approach */} }
153- { {- template " argo-rollouts.fullname" (dict " Values" (get .Values " argo-rollouts" )) } }
152+ { {- if and (index .Values " argo-rollouts" " enabled" ) } }
153+ { {/* For now use template from rollouts chart until better approach */} }
154+ { {- template " argo-rollouts.fullname" (dict " Values" (get .Values " argo-rollouts" )) } }
155+ { {- else } }
156+ { {- printf " argo-rollouts" } }
157+ { {- end } }
154158{ {- end } }
155159
156160
@@ -200,7 +204,7 @@ Determine argocd server url. Must be called with chart root context
200204 { {- $port := (required " ArgoCD is not enabled and .Values.global.external-argo-cd.server.port is not port" $argoCDSrv .port) | toString } }
201205 { {- $rootpath := (index .Values " global" " external-argo-cd" " server" " rootpath" ) } }
202206 { {- if and (eq $port " 80" ) } }
203- { {- printf " %s://%s%s" $protocol $svc $rootpath } }
207+ { {- printf " %s://%s%s" $protocol $svc $rootpath } }
204208 { {- else } }
205209 { {- printf " %s://%s:%s%s" $protocol $svc $port $rootpath } }
206210 { {- end } }
@@ -213,7 +217,7 @@ Determine argocd server url. Must be called with chart root context
213217Determine argocd server url witout the protocol. Must be called with chart root context
214218*/} }
215219{ {- define " codefresh-gitops-runtime.argocd.server.no-protocol-url" -} }
216- { {- $argoCDValues := (get .Values " argo-cd" ) } }
220+ { {- $argoCDValues := (get .Values " argo-cd" ) } }
217221{ {- if and (index .Values " argo-cd" " enabled" ) } }
218222 { {- $serverName := include " codefresh-gitops-runtime.argocd.server.servicename" . } }
219223 { {- $port := include " codefresh-gitops-runtime.argocd.server.serviceport" . } }
@@ -231,7 +235,7 @@ Determine argocd server url witout the protocol. Must be called with chart root
231235{ {- end} }
232236
233237{ {/*
234- Determine argocd server password.
238+ Determine argocd server password.
235239*/} }
236240{ {- define " codefresh-gitops-runtime.argocd.server.password" } }
237241 { {- if and (index .Values " argo-cd" " enabled" ) } }
@@ -265,7 +269,7 @@ valueFrom:
265269
266270
267271{ {/*
268- Determine argocd token password.
272+ Determine argocd token password.
269273*/} }
270274{ {- define " codefresh-gitops-runtime.argocd.server.token" } }
271275 { {- if and (eq (index .Values " global" " external-argo-cd" " auth" " type" ) " token" ) (index .Values " global" " external-argo-cd" " auth" " tokenSecretKeyRef" " name" ) (index .Values " global" " external-argo-cd" " auth" " tokenSecretKeyRef" " key" )} }
@@ -289,7 +293,7 @@ valueFrom:
289293{ {- end } }
290294
291295{ {/*
292- Determine argocd server password.
296+ Determine argocd server password.
293297*/} }
294298{ {- define " codefresh-gitops-runtime.argocd.server.username-env-var" } }
295299 { {- if and (index .Values " argo-cd" " enabled" ) } }
@@ -310,7 +314,7 @@ valueFrom:
310314{ {- end } }
311315
312316{ {/*
313- Determine argocd server password.
317+ Determine argocd server password.
314318*/} }
315319{ {- define " codefresh-gitops-runtime.argocd.server.username-cm" } }
316320 { {- if and (index .Values " argo-cd" " enabled" ) } }
@@ -323,10 +327,10 @@ Determine argocd server password.
323327{ {- end } }
324328
325329{ {/*
326- Determine argocd redis url
330+ Determine argocd redis url
327331*/} }
328332{ {- define " codefresh-gitops-runtime.argocd.redis.url" -} }
329- { {- $argoCDValues := (get .Values " argo-cd" ) } }
333+ { {- $argoCDValues := (get .Values " argo-cd" ) } }
330334{ {- if and (index .Values " argo-cd" " enabled" ) } }
331335 { {- $serviceName := include " codefresh-gitops-runtime.argocd.redis.servicename" . } }
332336 { {- $port := include " codefresh-gitops-runtime.argocd.redis.serviceport" . } }
@@ -458,7 +462,7 @@ Output comma separated list of installed runtime components
458462 { {- end } }
459463 { {- if not (index .Values " argo-cd" " enabled" ) } }
460464 { {- $eventReporter := dict " name" " event-reporter" " version" (get .Subcharts " cf-argocd-extras" ).Chart.AppVersion } }
461- { {- $comptList = append $comptList $eventReporter } }
465+ { {- $comptList = append $comptList $eventReporter } }
462466 { {- end } }
463467{ {- $comptList | toYaml } }
464468{ {- end } }
0 commit comments