[GH-ISSUE #428] If the local checkout is a submodule, in-container git commands don't work #295

Closed
opened 2026-03-01 21:42:09 +03:00 by kerem · 2 comments
Owner

Originally created by @obra on GitHub (Nov 20, 2020).
Original GitHub issue: https://github.com/nektos/act/issues/428

Hi!

I noticed that some of the jobs I have that work just great in production with GitHub actions fail in act.

I've tracked the problem down to the fact that when act copies the toplevel repository into the docker vms, it makes a verbatim copy, rather than a git clone.

In most situations, this is just fine. In my situation, however, the repo is typically checked out as a submodule of another repo, which means that .git is a file with the path of the git dir in the parent's .git.

Some of my actions rely on 'git ls-files', which can't work in the absence of the actual git directory.

Originally created by @obra on GitHub (Nov 20, 2020). Original GitHub issue: https://github.com/nektos/act/issues/428 Hi! I noticed that some of the jobs I have that work just great in production with GitHub actions fail in act. I've tracked the problem down to the fact that when act copies the toplevel repository into the docker vms, it makes a verbatim copy, rather than a git clone. In most situations, this is just fine. In my situation, however, the repo is typically checked out as a submodule of another repo, which means that .git is a file with the path of the git dir in the parent's .git. Some of my actions rely on 'git ls-files', which can't work in the absence of the actual git directory.
kerem 2026-03-01 21:42:09 +03:00
  • closed this issue
  • added the
    stale
    label
Author
Owner

@github-actions[bot] commented on GitHub (Jan 16, 2021):

Issue is stale and will be closed in 14 days unless there is new activity

<!-- gh-comment-id:761279533 --> @github-actions[bot] commented on GitHub (Jan 16, 2021): Issue is stale and will be closed in 14 days unless there is new activity
Author
Owner

@amlcodes commented on GitHub (Aug 4, 2022):

bump

<!-- gh-comment-id:1205500234 --> @amlcodes commented on GitHub (Aug 4, 2022): bump
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#295
No description provided.