Skip to content

Commit 0c066f6

Browse files
authored
Merge pull request #289 from natasha41575/deprecationdocs
kustomize: add deprecation warning to docs
2 parents f3d6133 + 9d1f803 commit 0c066f6

File tree

4 files changed

+57
-7
lines changed

4 files changed

+57
-7
lines changed

site/content/en/references/kustomize/kustomization/bases/_index.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,14 @@ description: >
88
---
99

1010
{{% pageinfo color="warning" %}}
11-
The `bases` field was deprecated in v2.1.0
11+
The `bases` field was deprecated in v2.1.0. This field will never be removed from the
12+
kustomize.config.k8s.io/v1beta1 Kustomization API, but it will not be included
13+
in the kustomize.config.k8s.io/v1 Kustomization API. When Kustomization v1 is available,
14+
we will announce the deprecation of the v1beta1 version. There will be at least
15+
two releases between deprecation and removal of Kustomization v1beta1 support from the
16+
kustomize CLI, and removal itself will happen in a future major version bump.
17+
18+
You can run `kustomize edit fix` to automatically convert `bases` to `resources`.
1219
{{% /pageinfo %}}
1320

1421
Move entries into the [resources](/references/kustomize/kustomization/resource)

site/content/en/references/kustomize/kustomization/patchesStrategicMerge/_index.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,20 @@ description: >
77
Patch resources using the strategic merge patch standard.
88
---
99

10+
{{% pageinfo color="warning" %}}
11+
The `patchesStrategicMerge` field was deprecated in v5.0.0. This field will never be removed from the
12+
kustomize.config.k8s.io/v1beta1 Kustomization API, but it will not be included
13+
in the kustomize.config.k8s.io/v1 Kustomization API. When Kustomization v1 is available,
14+
we will announce the deprecation of the v1beta1 version. There will be at least
15+
two releases between deprecation and removal of Kustomization v1beta1 support from the
16+
kustomize CLI, and removal itself will happen in a future major version bump.
17+
18+
Please move your `patchesStrategicMerge` into
19+
the [patches](/references/kustomize/kustomization/patches) field. This field supports patchesStrategicMerge,
20+
but with slightly different syntax. You can run `kustomize edit fix` to automatically convert
21+
`patchesStrategicMerge` to `patches`.
22+
{{% /pageinfo %}}
23+
1024
Each entry in this list should be either a relative
1125
file path or an inline content
1226
resolving to a partial or complete resource
@@ -59,7 +73,7 @@ patch that performs all the needed deletions.
5973
6074
A patch can refer to a resource by any of its previous names or kinds.
6175
For example, if a resource has gone through name-prefix transformations, it can refer to the
62-
resource by its current name, original name, or any intermediate name that it had.
76+
resource by its current name, original name, or any intermediate name that it had.
6377
6478
## Patching custom resources
6579

site/content/en/references/kustomize/kustomization/patchesjson6902/_index.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,20 @@ description: >
77
Patch resources using the [json 6902 standard](https://tools.ietf.org/html/rfc6902)
88
---
99

10+
{{% pageinfo color="warning" %}}
11+
The `patchesJson6902` field was deprecated in v5.0.0. This field will never be removed from the
12+
kustomize.config.k8s.io/v1beta1 Kustomization API, but it will not be included
13+
in the kustomize.config.k8s.io/v1 Kustomization API. When Kustomization v1 is available,
14+
we will announce the deprecation of the v1beta1 version. There will be at least
15+
two releases between deprecation and removal of Kustomization v1beta1 support from the
16+
kustomize CLI, and removal itself will happen in a future major version bump.
17+
18+
Please move your `patchesJson6902` into
19+
the [patches](/references/kustomize/kustomization/patches) field. This field supports patchesJson6902,
20+
but with slightly different syntax. You can run `kustomize edit fix` to automatically convert
21+
`patchesJson6902` to `patches`.
22+
{{% /pageinfo %}}
23+
1024
Each entry in this list should resolve to a kubernetes object and a JSON patch that will be applied
1125
to the object.
1226
The JSON patch is documented at <https://tools.ietf.org/html/rfc6902>
@@ -94,4 +108,4 @@ patchesJson6902:
94108
95109
A patch can refer to a resource by any of its previous names or kinds.
96110
For example, if a resource has gone through name-prefix transformations, it can refer to the
97-
resource by its current name, original name, or any intermediate name that it had.
111+
resource by its current name, original name, or any intermediate name that it had.

site/content/en/references/kustomize/kustomization/vars/_index.md

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,25 @@ description: >
99

1010
[replacements]: https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/replacements/
1111

12-
WARNING: There are plans to deprecate vars. For existing users of vars, we recommend migration to [replacements]
13-
as early as possible. There is a guide for convering vars to replacements at the bottom of this page under
14-
"convert vars to replacements". For new users, we recommend never using vars, and starting with replacements
15-
to avoid migration in the future.
12+
{{% pageinfo color="warning" %}}
13+
The `vars` field was deprecated in v5.0.0. This field will never be removed from the
14+
kustomize.config.k8s.io/v1beta1 Kustomization API, but it will not be included
15+
in the kustomize.config.k8s.io/v1 Kustomization API. When Kustomization v1 is available,
16+
we will announce the deprecation of the v1beta1 version. There will be at least
17+
two releases between deprecation and removal of Kustomization v1beta1 support from the
18+
kustomize CLI, and removal itself will happen in a future major version bump.
19+
20+
Please try to migrate to the
21+
the [replacements](/references/kustomize/kustomization/replacements) field. If you are
22+
unable to restructure your configuration to use replacements instead of vars, please
23+
ask for help in slack or file an issue for guidance.
24+
25+
We are experimentally attempting to
26+
automatically convert `vars` to `replacements` with `kustomize edit fix --vars`. However,
27+
converting vars to replacements in this way will potentially overwrite many resource files
28+
and the resulting files may not produce the same output when `kustomize build` is run.
29+
We recommend doing this in a clean git repository where the change is easy to undo.
30+
{{% /pageinfo %}}
1631

1732
Vars are used to capture text from one resource's field
1833
and insert that text elsewhere - a reflection feature.

0 commit comments

Comments
 (0)