Today, Drone.io, the leading open-source cloud-native Continuous Integration (CI) and Continuous Delivery (CD) platform, is announcing official support for configuration templates.

Get Started Using Drone.io With Configuration Templates

Large organizations can have difficulty maintaining large numbers of build configuration files. Very often, those configuration files are very similar or almost identical across projects. Some changes need to be made across all projects, for example, needing to change the version of a docker image.

To make this simpler, Drone has build templates that can be shared across projects. A project can use a template and provide project-specific information to alter the build.

This will simplify configuration management at organizations that have large numbers of similar configuration files; it will reduce the complexity of YAML files in individual repositories and will simplify the management of configuration across repositories.

Get started by reading the Templates documentation.

The first step is to define your configuration template, be it Jsonnet or Starlark. Both guides can be found in the docs, however, for this blog I will be demoing a Jsonnet template.

Drone Configuration Template

It’s important to note that all custom variables must start with ‘input.’

Once you are happy with the template, add it to the Drone database using either:

The next step is to define your .drone.yml

Drone Template Step
  • load refers to the template name you’ve just created
  • data refers the set of freeform template inputs

Once you’ve pushed the updated .drone.yml file to each of your repositories, you’re all set to go.

Drone is modern CI/CD. Container-native and available via open-source and an enterprise on-prem edition. Try it today.