From 4f54a6d1b7533b74ebbc00c074060ea63efa384d Mon Sep 17 00:00:00 2001 From: ss75710541 <75710541@qq.com> Date: Wed, 27 Apr 2022 16:27:38 +0800 Subject: [PATCH] fix: repo.GetAppDetails().Helm.GetParameterValueByName not get helm.values --- shared/argocd/service.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shared/argocd/service.go b/shared/argocd/service.go index 457614a7..6ba4d7f4 100644 --- a/shared/argocd/service.go +++ b/shared/argocd/service.go @@ -123,6 +123,9 @@ func (svc *argoCDService) GetAppDetails(ctx context.Context, appSource *v1alpha1 var has *shared.HelmAppSpec if appDetail.Helm != nil { paramsMap := map[string]*v1alpha1.HelmParameter{} + for _, param := range appDetail.Helm.Parameters { + paramsMap[param.Name] = param + } if appSource.Helm.Parameters != nil { for _, overrideParam := range appSource.Helm.Parameters { paramsMap[overrideParam.Name] = &v1alpha1.HelmParameter{ @@ -133,9 +136,6 @@ func (svc *argoCDService) GetAppDetails(ctx context.Context, appSource *v1alpha1 } } if appSource.Helm.Values != "" { - for _, param := range appDetail.Helm.Parameters { - paramsMap[param.Name] = param - } valuesParams, err := GetHelmParametersByValues(appSource.Helm.Values) if err != nil { return nil, err