Problem to solve
We have a great feature for bootstrapping an entire
.gitlab-ci.yml file from CI templates. This is great if you want to create a brand new CI file. But what if I have a mostly working file, but just want to add one "feature" to it. For instance deploy to Heroku or run unit tests or call out to Twilio to text me about a failure.
Some customers are already building things like this with librarys of "DevOps" tasks in a
/devops repo with things like:
- This is how you run AWS CLI in GitLab CI/CD
- Here's the standard for calling Sonatype
I think there is a space here for us to provide more convention and less configuration. For common places we integrate or common things we think people should run, we could provide smaller
job level templates (rather than the entire pipeline we provide today).
This is some ways is similar to what GitHub actions is providing, as they take the idea of "what do you want to do when building / testing / deploying" your code and break it into its component parts, and allow people to provide libraries of best practices and different ways of using a specific technology such as Node deploy to Azure, run some terraform, or even deploy a playlist to Spotify.
Note - since
snippets is already a thing in GitLab, I actually don't think we should name this feature "CI Snippets". It was a convinent way of making my idea clearer. Other ideas for naming:
- CI fragments
- CI building blocks
job level" templates accessable when building my CI yaml that will insert the job template at my cursor when selected. Ideally these would be instance or group level configuratable so as an admin I can publish my own along side the GitLab built in ones.
Which may not be the best from a UX perspective, but is hopefully illustrative of what I mean.
What does success look like, and how can we measure that?