Skip to content

Commit 5494f97

Browse files
authored
Merge pull request #35522 from KnVerey/revert-30348
Revert documentation of Kustomize bug as a feature
2 parents c3e2b6a + 39fb094 commit 5494f97

File tree

1 file changed

+3
-12
lines changed

1 file changed

+3
-12
lines changed

content/en/docs/tasks/manage-kubernetes-objects/kustomization.md

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -86,20 +86,12 @@ metadata:
8686
name: example-configmap-1-8mbdf7882g
8787
```
8888
89-
To generate a ConfigMap from an env file, add an entry to the `envs` list in `configMapGenerator`. This can also be used to set values from local environment variables by omitting the `=` and the value.
90-
91-
{{< note >}}
92-
It's recommended to use the local environment variable population functionality sparingly - an overlay with a patch is often more maintainable. Setting values from the environment may be useful when they cannot easily be predicted, such as a git SHA.
93-
{{< /note >}}
94-
95-
Here is an example of generating a ConfigMap with a data item from a `.env` file:
89+
To generate a ConfigMap from an env file, add an entry to the `envs` list in `configMapGenerator`. Here is an example of generating a ConfigMap with a data item from a `.env` file:
9690

9791
```shell
9892
# Create a .env file
99-
# BAZ will be populated from the local environment variable $BAZ
10093
cat <<EOF >.env
10194
FOO=Bar
102-
BAZ
10395
EOF
10496
10597
cat <<EOF >./kustomization.yaml
@@ -113,19 +105,18 @@ EOF
113105
The generated ConfigMap can be examined with the following command:
114106

115107
```shell
116-
BAZ=Qux kubectl kustomize ./
108+
kubectl kustomize ./
117109
```
118110

119111
The generated ConfigMap is:
120112

121113
```yaml
122114
apiVersion: v1
123115
data:
124-
BAZ: Qux
125116
FOO: Bar
126117
kind: ConfigMap
127118
metadata:
128-
name: example-configmap-1-892ghb99c8
119+
name: example-configmap-1-42cfbf598f
129120
```
130121

131122
{{< note >}}

0 commit comments

Comments
 (0)