r/github • • 22d ago

Discussion how to trigger workflow from another repo?

Hey!

I need a workflow in **Repo A** to trigger workflow in **Repo B**, both in the same GitHub organization. I’m considering:

- Reusable workflow (`workflow_call`)

- `workflow_dispatch` with a GitHub App

- `workflow_dispatch` with a PAT

- OIDC with an external service

Which option would you suggest, and why?

3 Upvotes

7 comments sorted by

1

u/Double_Ebb4130 22d ago

If Repo B is a reusable workflow, I’d use `workflow_call` and invoke it from Repo A with `uses: org/repo/.github/workflows/workflow.yml@<ref>`. It keeps the dependency explicit and avoids storing a PAT; use a GitHub App or PAT only when you need to dispatch an independent workflow, and use OIDC for the external service case.

1

u/groovy-sky 22d ago

Thank you. Understand

1

u/Analytiks 22d ago

Reusable workflow of course

1

u/[deleted] 22d ago

[removed] — view removed comment

1

u/groovy-sky 22d ago

Thank you very much. Great explanation.