Add test for multi-line string

xref: https://github.com/fluxcd/flux2/issues/3284

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
This commit is contained in:
Stefan Prodan 2023-11-21 08:57:34 +02:00
parent f88fe3d441
commit 05021967b0
No known key found for this signature in database
GPG Key ID: 3299AEB0E4085BAF
2 changed files with 42 additions and 8 deletions

View File

@ -2,8 +2,25 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- unimportant.yaml
- unimportant.yaml
images:
- name: container
newName: index.repo.fake/updated # {"$imagepolicy": "automation-ns:policy:name"}
newTag: v1.0.1 # {"$imagepolicy": "automation-ns:policy:tag"}
- name: container
newName: index.repo.fake/updated # {"$imagepolicy": "automation-ns:policy:name"}
newTag: v1.0.1 # {"$imagepolicy": "automation-ns:policy:tag"}
# Prove fix for https://github.com/fluxcd/flux2/issues/3284
patches:
- patch: |
- op: replace
path: /spec/template/spec/containers/0/volumeMounts
value:
- mountPath: /usr/share/wildfly/wildfly/standalone/configuration/appConfigMaps/WF
name: wf-config
- mountPath: /usr/share/wildfly/wildfly/standalone/configuration/appConfigMaps/xxx_config
name: xxx-config
- mountPath: /usr/share/wildfly/wildfly/standalone/log
name: wildfly-standalone-log
target:
group: apps
version: v1
kind: Deployment
name: sxxxxdadminservice

View File

@ -2,8 +2,25 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- unimportant.yaml
- unimportant.yaml
images:
- name: container
newName: replaced # {"$imagepolicy": "automation-ns:policy:name"}
newTag: v1 # {"$imagepolicy": "automation-ns:policy:tag"}
- name: container
newName: replaced # {"$imagepolicy": "automation-ns:policy:name"}
newTag: v1 # {"$imagepolicy": "automation-ns:policy:tag"}
# Prove fix for https://github.com/fluxcd/flux2/issues/3284
patches:
- patch: |
- op: replace
path: /spec/template/spec/containers/0/volumeMounts
value:
- mountPath: /usr/share/wildfly/wildfly/standalone/configuration/appConfigMaps/WF
name: wf-config
- mountPath: /usr/share/wildfly/wildfly/standalone/configuration/appConfigMaps/xxx_config
name: xxx-config
- mountPath: /usr/share/wildfly/wildfly/standalone/log
name: wildfly-standalone-log
target:
group: apps
version: v1
kind: Deployment
name: sxxxxdadminservice