Skip to content

feat: migrate common-ci-tasks to components

Related to common-ci-tasks#31

This is mostly a YAML schema change, but will allow common-ci-tasks to be published in the CI Component catalog.

Before Example

  - project: 'gitlab-com/gl-infra/common-ci-tasks'
    ref: v2.77 # renovate:managed
    file: templates/golang.yml

After Example

  - component: $CI_SERVER_FQDN/gitlab-com/gl-infra/common-ci-tasks/golang-build@v2.77

Why use perl instead of yq?

I found too many exceptions where yq was incorrectly rewriting YAML unrelated to this change (for instance replacing multiline strings with ugly single-line strings and lots of \n's).

Ultimately regex is reliable and predictable and I favour that over a flaky script.

Additionally, yq removes whitespace. Some of this can be correct with diff/patch hacks, but it even after that it's not perfect.

Edited by Andrew Newdigate

Merge request reports

Loading