rhd-gitops-example / services

Intra-Git repository promotions for GitOps.
Apache License 2.0
7 stars 8 forks source link

Automerge support for Tekton 0.12 #83

Closed mnuttall closed 4 years ago

mnuttall commented 4 years ago

In testing the https://github.com/rhd-gitops-example/services/tree/master/automerge-example @dibbles noticed errors of the form

HEAD detached from d88df61
[do-this-first : merge-pr] nothing to commit, working tree clean

when using Tekton Pipelines 0.12. These errors are not seen with Pipeline 0.11.3. The PipelineResources in the automerge-example need to be updated and re-tested with Tekton 0.12+. The failure is believed to be due to an optional refspec option introduced in the 0.12 timeframe. See https://github.com/tektoncd/pipeline/commit/8bc424db6249a4f4ab9240792a4a6b1ec00b4222

revision: Git revision (branch, tag, commit SHA or ref) to clone. You can use this to control what commit or branch is used. git checkout is used to switch to the revision, and will result in a detached HEAD in most cases. Use refspec along with revision if you want to checkout a particular branch without a detached HEAD. If no revision is specified, the resource will default to master.

Fetch the develop branch and switch to it (not detached)
  revision: develop
  refspec: refs/heads/develop:refs/heads/develop 

Ensure that both the 'standalone' and 'webhooks' PipelineResources are updated and tested.

mnuttall commented 4 years ago

Grabbing this as well for now to work in tandem with https://github.com/rhd-gitops-example/services/issues/55

mnuttall commented 4 years ago

I'll see if I can fix this for v1alpha1 on Tekton 0.12.x, independently of #101.