cloud-build-notifiers icon indicating copy to clipboard operation
cloud-build-notifiers copied to clipboard

githubissues notifier - use single notifier for multiple repositories

Open LeeU1911 opened this issue 1 year ago • 4 comments

Current configuration only allows a single repository

      githubRepo: myuser/myrepo

In a larger scale where teams work on multiple repositories, it is undesirable to deploy multiple Cloud Run notifier for each individual repository (from both cost and maintenance perspective)

With a small tweak to use repository full name from Build's default substitutions value of REPO_FULL_NAME, we can deploy the notifier once and use it for multiple repositories.

See default substitutions here: https://cloud.google.com/build/docs/configuring-builds/substitute-variable-values#using_default_substitutions

LeeU1911 avatar Feb 21 '24 11:02 LeeU1911

Hi, I just reviewed that PR, hopefully that resolves this issue?

prabenzom avatar Apr 02 '24 18:04 prabenzom

@prabenzom Yes, indeed. I created this issue to surface the problem in case and used to track the PR in case someone search for the same feature

VuKrampHub avatar Apr 03 '24 09:04 VuKrampHub

@prabenzom I have another commit to automatically set the assignee to the GitHub issue based on commit info. The added complexity is Cloud Build context itself doesn't contain this information and I have to look up via an additional call to GH API.

Is that something you would want to introduce in the upstream version? If yes, I'm more than happy to open another PR for it.

VuKrampHub avatar Apr 03 '24 09:04 VuKrampHub

Also want to ask: I saw someone threw the idea of having community-contributed notifier in the past, is that still on the radar?

VuKrampHub avatar Apr 03 '24 09:04 VuKrampHub