0

I have multiple yaml files, but we have to add a addition parameter only if specific template matches. Ex:

stages:
  - template: templates/my-java-service-v1.yaml@codeway
    parameters:

      lintingParams:
        skipSchemaValidation: false
      openJdkVersion: 17

Here openJdkVersion is an addition parameter should be added in existing yaml only if template templates/my-java-service-v1.yaml@codeway matches. In current recipes only supports for a sequencePath match. but here I have same sequencePath for multiple places, so need to filter with specific template.

  • Hi Manish; sounds like you need a custom recipe that first finds the associated key & value, and then in calls out to AddProperty when found to add the new key & value. There is no way to do this using only Yaml; You will need a custom Java recipe. – Tim Aug 18 '23 at 22:35
  • @Tim It would be great if you can provide me any link, steps or any sample example for custom recipe for this scenario. – manish kumar Aug 22 '23 at 04:41

0 Answers0