Can we wait for another repo workflow to complete before trigger the workflow in github actions?
Asked Answered
D

2

11

I have three github repos test, core and actual. I want to trigger a workflow in actual repo when the test repo and core repo workflows are completed successfully. Both test and core repo workflows run parallelly. Is there any way to do this in github actions?

Thanks in advance.

Disrate answered 8/10, 2021 at 5:38 Comment(0)
O
11

I have had this issue and any existing published actions do not really satisfy the same situation you're in so I've made a couple of actions that facilitate this:

return-dispatch This allows you to dispatch and get the run number needed to await completion.

await-remote-run This awaits completion and provides a pass or fail etc.

Both have examples and documentation, hope this suits

Ostrowski answered 11/4, 2022 at 2:12 Comment(0)
I
1

That does not seem possible, for non-interdependent workflows, especially for different repositories.

A workaround would be to use the Wait On Check Action (repo GitHub), which allows for a job to wait, through Checks API, for another to complete.

As mentioned in issue 3, it only supports jobs from one repository, so you might need to fork that action, and apply this patch in order to support other repositories as well.

Intracutaneous answered 8/10, 2021 at 6:24 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.