Support of YAML inheritance in .drone.yml

Is there any way to use yaml inheritances in .drone.yml file ? For example - i have 3 pipeline with some steps and in some of them I need to use exactly same docker image. it would be handy to separate image into yaml template kind of that way:

image: &image
    image: some-docker-image

--- 
kind: pipeline
(...)
steps: 
    - name: test1A
      <<: *image
      (...)
    - name: test1B
      <<: *image
      (...)
--- 
kind: pipeline
(...)
steps: 
    - name: test2A
      <<: *image
      (...)

1 Like

@adam,

See How to reduce Yaml boilerplate

You also have the option to create your own extension to extend the yaml syntax and / or implement custom pre-processing:
https://docs.drone.io/extensions/conversion/

Regards,
Harness Support