Skip to content

Commit

Permalink
Update to latest version of kyaml and cmd/config
Browse files Browse the repository at this point in the history
  • Loading branch information
mortent committed Sep 15, 2020
1 parent 28a7b40 commit 9480a1c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ require (
// Once there is a 0.18 release, we can import a semver release.
k8s.io/kubectl v0.0.0-20191219154910-1528d4eea6dd
sigs.k8s.io/cli-utils v0.20.0
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200914202724-1c6481d011df
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200914202724-1c6481d011df
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200915164007-ad7fed061e2f
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200915164007-ad7fed061e2f
)
4 changes: 4 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,8 @@ sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200914180048-6a0a909e7315 h1:kmPh9Pc
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200914180048-6a0a909e7315/go.mod h1:Hf7Qf/NCo3PEglHxO/2YkV2L9J5mL5eJTiNqzb+V5ww=
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200914202724-1c6481d011df h1:E+ngf8WXySmILexnoiYyef9hSZxKPTvvku2uUhbOJGw=
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200914202724-1c6481d011df/go.mod h1:w6fhpKsRmQlOkSS2be/3TPTDZzMsWQ5Kj9Av1lDPXFE=
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200915164007-ad7fed061e2f h1:mk5lAFWtjaxOKG78ei5A39Av0hG/Vy5wBZn1iQVT5cs=
sigs.k8s.io/kustomize/cmd/config v0.7.1-0.20200915164007-ad7fed061e2f/go.mod h1:w6fhpKsRmQlOkSS2be/3TPTDZzMsWQ5Kj9Av1lDPXFE=
sigs.k8s.io/kustomize/kyaml v0.7.1/go.mod h1:ne3F9JPhW2wrVaLslxBsEe6MQJQ9YK5rUutrdhBWXwI=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200903155941-0f49fef5ed58 h1:5Yjha1M1CQfaCl4SlUC/9lPJyQfy9ljgLaY19Ja+wus=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200903155941-0f49fef5ed58/go.mod h1:UTm64bSWVdBUA8EQoYCxVOaBQxUdIOr5LKWxA4GNbkw=
Expand All @@ -635,6 +637,8 @@ sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200914180048-6a0a909e7315 h1:D+cp/iWpVHy8
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200914180048-6a0a909e7315/go.mod h1:UTm64bSWVdBUA8EQoYCxVOaBQxUdIOr5LKWxA4GNbkw=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200914202724-1c6481d011df h1:mWY8Jj8q782kuOMTisAxK9lfezZM7Im3Fna17aGrWBY=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200914202724-1c6481d011df/go.mod h1:UTm64bSWVdBUA8EQoYCxVOaBQxUdIOr5LKWxA4GNbkw=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200915164007-ad7fed061e2f h1:vLk/yEunT6nBTybPdaoK8EcHiJZANIVsa4avZd79Xm0=
sigs.k8s.io/kustomize/kyaml v0.7.2-0.20200915164007-ad7fed061e2f/go.mod h1:UTm64bSWVdBUA8EQoYCxVOaBQxUdIOr5LKWxA4GNbkw=
sigs.k8s.io/structured-merge-diff v0.0.0-20190525122527-15d366b2352e/go.mod h1:wWxsB5ozmmv/SG7nM11ayaAW51xMvak/t1r0CSlcokI=
sigs.k8s.io/structured-merge-diff v0.0.0-20190817042607-6149e4549fca/go.mod h1:IIgPezJWb76P0hotTxzDbWsMYB8APh18qZnxkomBpxA=
sigs.k8s.io/structured-merge-diff v1.0.1-0.20191108220359-b1b620dd3f06/go.mod h1:/ULNhyfzRopfcjskuui0cTITekDduZ7ycKN3oUT9R18=
Expand Down
5 changes: 2 additions & 3 deletions internal/util/openapi/openapi.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,13 @@ func ReadOpenAPISchemaFromDisk(path string) ([]byte, error) {
func ConfigureOpenAPISchema(openAPISchema []byte) error {
openapi.SuppressBuiltInSchemaUse()

_, err := openapi.AddSchema(openAPISchema)
err := openapi.AddSchema(openAPISchema)
if err != nil {
return err
}
// Also add make sure the Kustomize openAPI is always added regardless
// of where we got the Kubernetes openAPI schema.
// TODO: Refactor the openapi package in kyaml so we don't need to
// know the name of the kustomize asset here.
_, err = openapi.AddSchema(kustomizationapi.MustAsset("openapi/kustomizationapi/swagger.json"))
return err
return openapi.AddSchema(kustomizationapi.MustAsset("openapi/kustomizationapi/swagger.json"))
}

0 comments on commit 9480a1c

Please sign in to comment.