fix(examples): move examples from patchesStrategicMerge to patches

This commit is contained in:
Daniel Strebel
2023-06-09 22:32:19 +02:00
parent 336bc14e1a
commit d37c0eb477
15 changed files with 74 additions and 74 deletions

View File

@@ -44,9 +44,9 @@ EOF
```
## Inline Patch for PatchesStrategicMerge
## Inline Patch
Create an overlay and add an inline patch in `patchesStrategicMerge` field to the kustomization file
Create an overlay and add an inline patch in the `patches` field to the kustomization file
to change the image from `nginx` to `nginx:latest`.
<!-- @addSMPatch @test -->
@@ -57,18 +57,18 @@ cat <<EOF >$SMP_OVERLAY/kustomization.yaml
resources:
- ../base
patchesStrategicMerge:
- |-
apiVersion: apps/v1
kind: Deployment
metadata:
name: deploy
spec:
template:
spec:
containers:
- name: nginx
image: nginx:latest
patches:
- patch: |-
apiVersion: apps/v1
kind: Deployment
metadata:
name: deploy
spec:
template:
spec:
containers:
- name: nginx
image: nginx:latest
EOF
```
@@ -110,18 +110,18 @@ cat <<EOF >$SMP_OVERLAY/kustomization.yaml
resources:
- ../base
patchesStrategicMerge:
- |-
apiVersion: apps/v1
kind: Deployment
metadata:
name: deploy
spec:
template:
spec:
containers:
- name: nginx
$patch: delete
patches:
- patch: |-
apiVersion: apps/v1
kind: Deployment
metadata:
name: deploy
spec:
template:
spec:
containers:
- name: nginx
$patch: delete
EOF
```