galasa-dev / projectmanagement

Project Management repo for Issues and ZenHub
7 stars 3 forks source link

Trigger recycle-prod1 from end of OBR GH Actions workflow #1933

Closed jadecarino closed 6 days ago

jadecarino commented 1 month ago

Story

As a Galasa developer, I want the prod1 ecosystem to be recycled after the OBR runtime images have been rebuilt in the GH Actions workflow, so that the prod1 ecosystem is running the very latest code.

Background

In the current Tekton builds, after the OBR repo and runtime images (boot-embedded etc) are rebuilt, a recycle of the prod1 ecosystem is triggered which recycles the ecosystems deployments, so the ecosystem has the latest code. This is done using the Tekton CLI.

Now we are moving the build process to GH Actions, we need a way to trigger the recycle-prod1 pipeline from a GH Actions workflow, without using Tekton CLI.

I propose that we update the webhook we have set up in the galasa-dev organisation to be triggered by Workflow events (currently these types of events do not trigger the webhook), then the GitHub Event Monitor can receive and process these types of events. We would then need to create a new EventListener which triggers the recycle-prod1 pipeline.

However, we can't implement this solution fully yet as the prod1 ecosystem is not going to be switched over to use the new GHCR images until the new GH build process is fully complete and stable?

Tasks

jadecarino commented 1 month ago

I have tested the new EventListener, Ingress and ConfigMap and it successfully kicks off recycleprod1 in Tekton following a successful workflow run of the OBR build in GitHub Actions. I am leaving task 'Update the galasa-dev webhook event list' incomplete for now as this disables this trigger - as while the Tekton and GH builds are running in parallel, both will at some point call recycle-prod1 in Tekton and this means the end part of the chain will duplicate, which could cause issues.