[PR #1784] [MERGED] fix: remove hardcoded reference to github.com when using reusable remote workflows and remote actions #2127

Closed
opened 2026-03-01 21:54:07 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/nektos/act/pull/1784
Author: @shubhbapna
Created: 5/1/2023
Status: Merged
Merged: 5/3/2023
Merged by: @mergify[bot]

Base: masterHead: issue-1588


📝 Commits (3)

  • 4c21615 fix filename for remote reusable workflow and remove hardcoded reference to github.com
  • 0dc2920 remove hardcoded reference to github.com for remote action
  • 308edcd Merge branch 'master' into issue-1588

📊 Changes

2 files changed (+21 additions, -16 deletions)

View changed files

📝 pkg/runner/reusable_workflow.go (+16 -10)
📝 pkg/runner/step_action_remote.go (+5 -6)

📄 Description

fixes #1588

By removing reference to the hardcoded github.com and instead using serverURL from github context, we can start controlling where we clone these actions/workflows from. So for example if we want act to use ssh then we can simply pass the following option:

--env GITHUB_SERVER_URL=ssh://git@github.com

Moreover, I noticed that for reusable workflows we are cloning the repositories in a directory named - {owner}-{repo}-.github-workflows-{filename}@{ref}. However if we change this directory name to be {owner}-{repo}@{ref}, we will be able to reduce the number of clones act will make when using multiple reusable workflows from the same repository.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/nektos/act/pull/1784 **Author:** [@shubhbapna](https://github.com/shubhbapna) **Created:** 5/1/2023 **Status:** ✅ Merged **Merged:** 5/3/2023 **Merged by:** [@mergify[bot]](https://github.com/apps/mergify) **Base:** `master` ← **Head:** `issue-1588` --- ### 📝 Commits (3) - [`4c21615`](https://github.com/nektos/act/commit/4c21615be70eeb72c165e7e390904d481f784fd3) fix filename for remote reusable workflow and remove hardcoded reference to github.com - [`0dc2920`](https://github.com/nektos/act/commit/0dc2920a82e868dc44c2e2a8d324cd2ba40cb599) remove hardcoded reference to github.com for remote action - [`308edcd`](https://github.com/nektos/act/commit/308edcd4150f60f1203489511e2da8d168c7c4ee) Merge branch 'master' into issue-1588 ### 📊 Changes **2 files changed** (+21 additions, -16 deletions) <details> <summary>View changed files</summary> 📝 `pkg/runner/reusable_workflow.go` (+16 -10) 📝 `pkg/runner/step_action_remote.go` (+5 -6) </details> ### 📄 Description fixes #1588 By removing reference to the hardcoded `github.com` and instead using `serverURL` from github context, we can start controlling where we clone these actions/workflows from. So for example if we want `act` to use ssh then we can simply pass the following option: ``` --env GITHUB_SERVER_URL=ssh://git@github.com ``` Moreover, I noticed that for reusable workflows we are cloning the repositories in a directory named - `{owner}-{repo}-.github-workflows-{filename}@{ref}`. However if we change this directory name to be `{owner}-{repo}@{ref}`, we will be able to reduce the number of clones `act` will make when using multiple reusable workflows from the same repository. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-01 21:54:07 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#2127
No description provided.