From 947025eb8775891484671651fe816ff2596f4717 Mon Sep 17 00:00:00 2001 From: "Steven E. Harris" Date: Sun, 7 May 2023 18:09:22 -0400 Subject: [PATCH 1/2] Update set of available Helm tool versions Introduce version 3.11.3, and make that the default version. Remove version 3.9.2. --- README.rst | 4 ++-- kustomize/private/tools/helm/toolchain.bzl | 17 +++++++++-------- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/README.rst b/README.rst index cc119b3..79b410d 100644 --- a/README.rst +++ b/README.rst @@ -153,10 +153,10 @@ At present, these rules can load the following versions of these tools: * :tool:`helm` - * `v3.11.2 `__ (default) + * `v3.11.3 `__ (default) + * `v3.11.2 `__ * `v3.11.0 `__ * `v3.10.3 `__ - * `v3.9.2 `__ Rules ===== diff --git a/kustomize/private/tools/helm/toolchain.bzl b/kustomize/private/tools/helm/toolchain.bzl index 802ae6c..51f7333 100644 --- a/kustomize/private/tools/helm/toolchain.bzl +++ b/kustomize/private/tools/helm/toolchain.bzl @@ -3,6 +3,14 @@ visibility("public") _TOOLS_BY_RELEASE = { + "v3.11.3": { + struct(os = "darwin", arch = "amd64"): "9d029df37664b50e427442a600e4e065fa75fd74dac996c831ac68359654b2c4", + struct(os = "darwin", arch = "arm64"): "267e4d50b68e8854b9cc44517da9ab2f47dec39787fed9f7eba42080d61ac7f8", + struct(os = "linux", arch = "amd64"): "ca2d5d40d4cdfb9a3a6205dd803b5bc8def00bd2f13e5526c127e9b667974a89", + struct(os = "linux", arch = "arm64"): "9f58e707dcbe9a3b7885c4e24ef57edfb9794490d72705b33a93fa1f3572cce4", + struct(os = "windows", arch = "amd64"): "ae146d2a90600c6958bc801213daef467237cf475e26ab3f476dfb8e0d9549b7", + # NB: There is no Windows build available for the ARM64 architecture. + }, "v3.11.2": { struct(os = "darwin", arch = "amd64"): "404938fd2c6eff9e0dab830b0db943fca9e1572cd3d7ee40904705760faa390f", struct(os = "darwin", arch = "arm64"): "f61a3aa55827de2d8c64a2063fd744b618b443ed063871b79f52069e90813151", @@ -26,16 +34,9 @@ _TOOLS_BY_RELEASE = { struct(os = "linux", arch = "arm64"): "260cda5ff2ed5d01dd0fd6e7e09bc80126e00d8bdc55f3269d05129e32f6f99d", struct(os = "windows", arch = "amd64"): "5d97aa26830c1cd6c520815255882f148040587fd7cdddb61ef66e4c081566e0", }, - "v3.9.2": { - struct(os = "darwin", arch = "amd64"): "35d7ff8bea561831d78dce8f7bf614a7ffbcad3ff88d4c2f06a51bfa51c017e2", - struct(os = "darwin", arch = "arm64"): "6250a6b92603a9c14194932e9dc22380ac423779519521452163493db33b68c8", - struct(os = "linux", arch = "amd64"): "3f5be38068a1829670440ccf00b3b6656fd90d0d9cfd4367539f3b13e4c20531", - struct(os = "linux", arch = "arm64"): "e4e2f9aad786042d903534e3131bc5300d245c24bbadf64fc46cca1728051dbc", - struct(os = "windows", arch = "amd64"): "d0d98a2a1f4794fcfc437000f89d337dc9278b6b7672f30e164f96c9413a7a74", - }, } -_DEFAULT_TOOL_VERSION = "v3.11.2" +_DEFAULT_TOOL_VERSION = "v3.11.3" def known_release_versions(): return _TOOLS_BY_RELEASE.keys() From 1483d85efb99a57516f0264604d3a3848cc53480 Mon Sep 17 00:00:00 2001 From: "Steven E. Harris" Date: Sun, 7 May 2023 18:04:38 -0400 Subject: [PATCH 2/2] Update set of available kustomize tool versions Introduce version 5.0.2, and make that the default version. Remove version 4.5.5. Accommodate kubernetes-sigs/kustomize#4999 by relocating the extracted Helm chart in the unit test data, placing the directory one level deeper within a new containing directory distinguishing the files for each version. --- README.rst | 12 ++++++------ kustomize/private/tools/kustomize/toolchain.bzl | 16 +++++++++------- test/testdata/helm/charts/BUILD.bazel | 2 +- .../{ => minecraft-3.1.4}/minecraft/.helmignore | 0 .../{ => minecraft-3.1.4}/minecraft/Chart.yaml | 0 .../{ => minecraft-3.1.4}/minecraft/README.md | 0 .../minecraft/ci/test-values.yaml | 0 .../minecraft/templates/NOTES.txt | 0 .../minecraft/templates/_helpers.tpl | 0 .../minecraft/templates/datadir-pvc.yaml | 0 .../minecraft/templates/deployment.yaml | 0 .../minecraft/templates/extraports-ing.yaml | 0 .../minecraft/templates/extraports-svc.yaml | 0 .../minecraft/templates/minecraft-svc.yaml | 0 .../minecraft/templates/rcon-svc.yaml | 0 .../minecraft/templates/secrets.yaml | 0 .../{ => minecraft-3.1.4}/minecraft/values.yaml | 0 test/testdata/overlay/golden.yaml | 4 ++-- 18 files changed, 18 insertions(+), 16 deletions(-) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/.helmignore (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/Chart.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/README.md (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/ci/test-values.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/NOTES.txt (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/_helpers.tpl (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/datadir-pvc.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/deployment.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/extraports-ing.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/extraports-svc.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/minecraft-svc.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/rcon-svc.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/templates/secrets.yaml (100%) rename test/testdata/helm/charts/{ => minecraft-3.1.4}/minecraft/values.yaml (100%) diff --git a/README.rst b/README.rst index 79b410d..0c7b565 100644 --- a/README.rst +++ b/README.rst @@ -122,18 +122,18 @@ In order to use these rules in your Bazel project, you must instruct Bazel to do .. code:: bazel - bazel_dep(name = "rules_kustomize", version = "0.3.1") + bazel_dep(name = "rules_kustomize", version = "0.3.3") This declaration registers a particular version of the :tool:`helm` and :tool:`kustomize` tools, respectively. By default, it registers `the latest version known to the rules `_. You can specify a preferred version for each tool by supplying the known version slug (e.g. "v4.5.7") as an argument to the respective module extension's :field:`download` tag. .. code:: bazel - bazel_dep(name = "rules_kustomize", version = "0.3.1") + bazel_dep(name = "rules_kustomize", version = "0.3.3") kustomize = use_extension("@rules_kustomize//kustomize:extensions.bzl", "kustomize") - kustomize.download(version = "v4.5.7") + kustomize.download(version = "v5.0.1") helm = use_extension("@rules_kustomize//kustomize:extensions.bzl", "helm") - helm.download(version = "v3.9.2") + helm.download(version = "v3.11.0") If any number of modules wind up specifying different version values for these tags, the latest version—per :term:`Semantic Versioning` sorting—among the proposed candidate versions wins. If any of the tags also include the :field:`tolerate_newer` attribute with a value of :value:`False`, then no competing version newer than that tag's proposed version can win. @@ -146,10 +146,10 @@ At present, these rules can load the following versions of these tools: * :tool:`kustomize` - * `v5.0.1 `__ (default) + * `v5.0.2 `__ (default) + * `v5.0.1 `__ * `v5.0.0 `__ * `v4.5.7 `__ - * `v4.5.5 `__ * :tool:`helm` diff --git a/kustomize/private/tools/kustomize/toolchain.bzl b/kustomize/private/tools/kustomize/toolchain.bzl index c707dab..30db58a 100644 --- a/kustomize/private/tools/kustomize/toolchain.bzl +++ b/kustomize/private/tools/kustomize/toolchain.bzl @@ -3,6 +3,14 @@ visibility("public") _TOOLS_BY_RELEASE = { + "v5.0.2": { + struct(os = "darwin", arch = "amd64"): "26bedd5680d8af0e91b5b0ef470d384b158f160413f9e68a0ad23e2b8d17a462", + struct(os = "darwin", arch = "arm64"): "63b09921ed392c0697ec56118bb46f25fb7c3454d5f9ddaf49b8d1ad96cac12b", + struct(os = "linux", arch = "amd64"): "112782e22bc5d4f09868a633eda515f48f16fa2338df51844096c7107ca174a1", + struct(os = "linux", arch = "arm64"): "291e19b486790177bc62695328467c2ff973a91d0e7fdf96b902bb073d9b9724", + struct(os = "windows", arch = "amd64"): "6adad0254103bca5673a4dd3b35fe4aa7e52ff6620413ba4a921271c8aa58d6c", + struct(os = "windows", arch = "arm64"): "e60ec24a1df34bd2ddb4770fb88db3348b51bbbd3bc3e32bf140ff0ae6f904e6", + }, "v5.0.1": { struct(os = "darwin", arch = "amd64"): "4a2b9f7fad0355c8bea08da6dd9c48e790df5f357983280998d80b8dc7ad3def", struct(os = "darwin", arch = "arm64"): "b264fe931e85d8ca7c7ac47872695b1fa39fe2b73cfc0d58cbdca0bde69d0bc0", @@ -25,15 +33,9 @@ _TOOLS_BY_RELEASE = { struct(os = "linux", arch = "arm64"): "65665b39297cc73c13918f05bbe8450d17556f0acd16242a339271e14861df67", struct(os = "windows", arch = "amd64"): "79af25f97bb10df999e540def94e876555696c5fe42d4c93647e28f83b1efc55", }, - "v4.5.5": { - struct(os = "darwin", arch = "amd64"): "f604eaf1083659cd46aaffcc81bf13351a76a2d245823e2345dbb8b840622bde", - struct(os = "linux", arch = "amd64"): "bba81aa61dba057db1d5abeddf1e522b568b2d906ab67a5c80935e97302c8773", - struct(os = "linux", arch = "arm64"): "c491191b81c97ddebc4844f9254683ecfc80f40dfb15510433cbfdaeb86627c3", - struct(os = "windows", arch = "amd64"): "a72d7e5bbce1388c829d17208c34bf11df69215e7e496e05d8156a0d44b7de3d", - }, } -_DEFAULT_TOOL_VERSION = "v5.0.1" +_DEFAULT_TOOL_VERSION = "v5.0.2" def known_release_versions(): return _TOOLS_BY_RELEASE.keys() diff --git a/test/testdata/helm/charts/BUILD.bazel b/test/testdata/helm/charts/BUILD.bazel index 4885677..e617d6e 100644 --- a/test/testdata/helm/charts/BUILD.bazel +++ b/test/testdata/helm/charts/BUILD.bazel @@ -1,7 +1,7 @@ filegroup( name = "charts", srcs = glob([ - "minecraft/**", + "minecraft-3.1.4/minecraft/**", ]), visibility = ["//test:__subpackages__"], ) diff --git a/test/testdata/helm/charts/minecraft/.helmignore b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/.helmignore similarity index 100% rename from test/testdata/helm/charts/minecraft/.helmignore rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/.helmignore diff --git a/test/testdata/helm/charts/minecraft/Chart.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/Chart.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/Chart.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/Chart.yaml diff --git a/test/testdata/helm/charts/minecraft/README.md b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/README.md similarity index 100% rename from test/testdata/helm/charts/minecraft/README.md rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/README.md diff --git a/test/testdata/helm/charts/minecraft/ci/test-values.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/ci/test-values.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/ci/test-values.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/ci/test-values.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/NOTES.txt b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/NOTES.txt similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/NOTES.txt rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/NOTES.txt diff --git a/test/testdata/helm/charts/minecraft/templates/_helpers.tpl b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/_helpers.tpl similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/_helpers.tpl rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/_helpers.tpl diff --git a/test/testdata/helm/charts/minecraft/templates/datadir-pvc.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/datadir-pvc.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/datadir-pvc.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/datadir-pvc.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/deployment.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/deployment.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/deployment.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/deployment.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/extraports-ing.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/extraports-ing.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/extraports-ing.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/extraports-ing.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/extraports-svc.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/extraports-svc.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/extraports-svc.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/extraports-svc.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/minecraft-svc.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/minecraft-svc.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/minecraft-svc.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/minecraft-svc.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/rcon-svc.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/rcon-svc.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/rcon-svc.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/rcon-svc.yaml diff --git a/test/testdata/helm/charts/minecraft/templates/secrets.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/secrets.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/templates/secrets.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/templates/secrets.yaml diff --git a/test/testdata/helm/charts/minecraft/values.yaml b/test/testdata/helm/charts/minecraft-3.1.4/minecraft/values.yaml similarity index 100% rename from test/testdata/helm/charts/minecraft/values.yaml rename to test/testdata/helm/charts/minecraft-3.1.4/minecraft/values.yaml diff --git a/test/testdata/overlay/golden.yaml b/test/testdata/overlay/golden.yaml index 3d4d8fe..9af1438 100644 --- a/test/testdata/overlay/golden.yaml +++ b/test/testdata/overlay/golden.yaml @@ -8,7 +8,7 @@ data: kind: ConfigMap metadata: labels: - app.kubernetes.io/managed-by: kustomize-v5.0.1 + app.kubernetes.io/managed-by: kustomize-v5.0.2 name: translations-t8gcg5kbfg namespace: test --- @@ -16,7 +16,7 @@ apiVersion: v1 kind: Pod metadata: labels: - app.kubernetes.io/managed-by: kustomize-v5.0.1 + app.kubernetes.io/managed-by: kustomize-v5.0.2 name: show-config namespace: test spec: