diff --git a/src/go.mod b/src/go.mod index 706acfc02..5986daa2d 100644 --- a/src/go.mod +++ b/src/go.mod @@ -70,7 +70,7 @@ require ( golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 gopkg.in/h2non/gock.v1 v1.0.16 gopkg.in/yaml.v2 v2.4.0 - helm.sh/helm/v3 v3.10.1 + helm.sh/helm/v3 v3.10.3 k8s.io/api v0.25.2 k8s.io/apimachinery v0.25.2 k8s.io/client-go v0.25.2 diff --git a/src/go.sum b/src/go.sum index 0894f3a1a..234a2e0f6 100644 --- a/src/go.sum +++ b/src/go.sum @@ -1966,8 +1966,8 @@ gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81 gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= gotest.tools/v3 v3.0.3 h1:4AuOwCGf4lLR9u3YOe2awrHygurzhO/HeQ6laiA6Sx0= gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= -helm.sh/helm/v3 v3.10.1 h1:uTnNlYx8QcTSNA4ZJ50Llwife4CSohUY4ehumyVf2QE= -helm.sh/helm/v3 v3.10.1/go.mod h1:CXOcs02AYvrlPMWARNYNRgf2rNP7gLJQsi/Ubd4EDrI= +helm.sh/helm/v3 v3.10.3 h1:wL7IUZ7Zyukm5Kz0OUmIFZgKHuAgByCrUcJBtY0kDyw= +helm.sh/helm/v3 v3.10.3/go.mod h1:CXOcs02AYvrlPMWARNYNRgf2rNP7gLJQsi/Ubd4EDrI= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/src/vendor/helm.sh/helm/v3/pkg/chartutil/create.go b/src/vendor/helm.sh/helm/v3/pkg/chartutil/create.go index ca79e7ab2..3a8f3cc5a 100644 --- a/src/vendor/helm.sh/helm/v3/pkg/chartutil/create.go +++ b/src/vendor/helm.sh/helm/v3/pkg/chartutil/create.go @@ -312,7 +312,7 @@ spec: imagePullPolicy: {{ .Values.image.pullPolicy }} ports: - name: http - containerPort: 80 + containerPort: {{ .Values.service.port }} protocol: TCP livenessProbe: httpGet: diff --git a/src/vendor/helm.sh/helm/v3/pkg/chartutil/jsonschema.go b/src/vendor/helm.sh/helm/v3/pkg/chartutil/jsonschema.go index 753dc98c1..7b9768fd3 100644 --- a/src/vendor/helm.sh/helm/v3/pkg/chartutil/jsonschema.go +++ b/src/vendor/helm.sh/helm/v3/pkg/chartutil/jsonschema.go @@ -55,7 +55,13 @@ func ValidateAgainstSchema(chrt *chart.Chart, values map[string]interface{}) err } // ValidateAgainstSingleSchema checks that values does not violate the structure laid out in this schema -func ValidateAgainstSingleSchema(values Values, schemaJSON []byte) error { +func ValidateAgainstSingleSchema(values Values, schemaJSON []byte) (reterr error) { + defer func() { + if r := recover(); r != nil { + reterr = fmt.Errorf("unable to validate schema: %s", r) + } + }() + valuesData, err := yaml.Marshal(values) if err != nil { return err diff --git a/src/vendor/helm.sh/helm/v3/pkg/repo/index.go b/src/vendor/helm.sh/helm/v3/pkg/repo/index.go index 1b65ac497..60cfe5801 100644 --- a/src/vendor/helm.sh/helm/v3/pkg/repo/index.go +++ b/src/vendor/helm.sh/helm/v3/pkg/repo/index.go @@ -118,6 +118,10 @@ func LoadIndexFile(path string) (*IndexFile, error) { // MustAdd adds a file to the index // This can leave the index in an unsorted state func (i IndexFile) MustAdd(md *chart.Metadata, filename, baseURL, digest string) error { + if i.Entries == nil { + return errors.New("entries not initialized") + } + if md.APIVersion == "" { md.APIVersion = chart.APIVersionV1 } @@ -339,6 +343,10 @@ func loadIndex(data []byte, source string) (*IndexFile, error) { for name, cvs := range i.Entries { for idx := len(cvs) - 1; idx >= 0; idx-- { + if cvs[idx] == nil { + log.Printf("skipping loading invalid entry for chart %q from %s: empty entry", name, source) + continue + } if cvs[idx].APIVersion == "" { cvs[idx].APIVersion = chart.APIVersionV1 } diff --git a/src/vendor/helm.sh/helm/v3/pkg/repo/repo.go b/src/vendor/helm.sh/helm/v3/pkg/repo/repo.go index 6f1e90dad..ee80d04f4 100644 --- a/src/vendor/helm.sh/helm/v3/pkg/repo/repo.go +++ b/src/vendor/helm.sh/helm/v3/pkg/repo/repo.go @@ -100,6 +100,9 @@ func (r *File) Remove(name string) bool { cp := []*Entry{} found := false for _, rf := range r.Repositories { + if rf == nil { + continue + } if rf.Name == name { found = true continue diff --git a/src/vendor/modules.txt b/src/vendor/modules.txt index 1e80b67e9..df417346b 100644 --- a/src/vendor/modules.txt +++ b/src/vendor/modules.txt @@ -1056,7 +1056,7 @@ gopkg.in/yaml.v2 # gopkg.in/yaml.v3 v3.0.1 ## explicit gopkg.in/yaml.v3 -# helm.sh/helm/v3 v3.10.1 +# helm.sh/helm/v3 v3.10.3 ## explicit; go 1.18 helm.sh/helm/v3/cmd/helm/search helm.sh/helm/v3/internal/fileutil