Skip to content

Support .yaml extension for CI/CD Components

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

I started looking at the CI/CD Catalog support and was a bit disappointed that it said

  • In single files ending in .yml for each component, like templates/secret-detection.yml.
  • In sub-directories containing template.yml files as entry points, [...]

So here is my

Proposal

In addition to a .yml extension, support a .yaml extension for CI/CD Components. The latter is the recommended extension per YAML FAQ.

There is work in progress to allow a .yaml extension for the CI/CD pipeline as well (see #26169 and #384725) so adding support to the CI/CD Components seems only natural.

I had a very quick look at the code below app/models/ci/catalog/ and it appears to work exclusively with .yml extensions 😢

Patching the TEMPLATE_PATH_REGEX in components_project.rb seems trivial enough but I am not sure how to go about TEMPLATE_FILE and the two File.join invocations that create a file with .yml extension. Also, I haven't looked whether anything else is involved.

Edited by 🤖 GitLab Bot 🤖