Skip to content

feat: Add workflow URL to EC2 instance tags #4658

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

roberto-civitas
Copy link

Add the workflow_url to the instance tags so that it's easier to identify which build is being run by the instance.

The property is passed along from the webhook lambda, as part of the SQS event.

@roberto-civitas roberto-civitas requested a review from a team as a code owner July 10, 2025 18:28
@roberto-civitas roberto-civitas changed the title Add workflow URL to EC2 instance tags feat: Add workflow URL to EC2 instance tags Jul 10, 2025
@roberto-civitas roberto-civitas force-pushed the add-build-url-to-instance-tags branch 3 times, most recently from 8a5b66b to b98f8bd Compare July 10, 2025 18:43
@roberto-civitas roberto-civitas force-pushed the add-build-url-to-instance-tags branch from b98f8bd to 343f078 Compare July 10, 2025 18:45
@npalm
Copy link
Member

npalm commented Jul 14, 2025

@roberto-civitas thx for the PR. Good idea, but I am afraid it won't work.

Runners are indeed created based on the workflow_job event, however which job starts on the runner is orechestrated by GitHub. So the actual job running on a runner is not alwasy the event that leading to creation of the runner. The module supports XRay which allows you to see correlation between which events is causing runner creation.

Next to het workflow_job event created there is a event for in_progress. This event could be used to tag an instance with the job in progress. It should not hard to correlate based ont he the event since this event contians the runner name as well.

Wondering what your thoughts are.

@roberto-civitas
Copy link
Author

Thank you for having a look at the PR. I will modify it so that it uses the event you suggest.

@npalm
Copy link
Member

npalm commented Jul 15, 2025

Thank you for having a look at the PR. I will modify it so that it uses the event you suggest.

Maybe good to have a short discussion on how to implement this. This to avoid you wast time on a proposal that is not fitting. My first thought would be having an extra lambda as part of the control plane. But no time to dig in so far.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants