mirror of
https://github.com/nektos/act.git
synced 2026-04-26 09:25:54 +03:00
[GH-ISSUE #307] Cannot find local action #219
Labels
No labels
area/action
area/cli
area/docs
area/image
area/runner
area/workflow
backlog
confirmed/not-planned
kind/bug
kind/discussion
kind/external
kind/feature-request
kind/question
meta/duplicate
meta/invalid
meta/need-more-info
meta/resolved
meta/wontfix
meta/workaround
needs-work
pull-request
review/not-planned
size/M
size/XL
size/XXL
stale
stale-exempt
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/act#219
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @aeisenberg on GitHub (Jul 17, 2020).
Original GitHub issue: https://github.com/nektos/act/issues/307
I have a job that looks like this:
When I run this on CI, there are no problems. But, when I run this through
act -j mock-jobI get this error:Note that the
init/action.ymlfile exists at/Users/andrew.eisenberg/repos/my-repo/init/action.yaml.It looks like github is running the entire job inside of the docker container, whereas act is running some parts outside of it. Notably, it is looking for the action files on the host filesystem and the rest seems to be in the docker container.
@aeisenberg commented on GitHub (Jul 19, 2020):
My guess is that this line is incorrect:
github.com/nektos/act@64b8d2afa4/pkg/runner/step_context.go (L52)It is using the local filesystem path to get to the action. But, I think it should be the path inside of the docker image.
@benwinding commented on GitHub (Aug 17, 2020):
Seems to work if you set the reference to the local action from the root of the
gitfolderGithub workflow
Local action
@aeisenberg commented on GitHub (Aug 17, 2020):
Thanks for your response, though if I do what you are suggesting, then I'm pretty sure that the workflow would fail when I run it on CI.
@github-actions[bot] commented on GitHub (Oct 17, 2020):
Issue is stale and will be closed in 7 days unless there is new activity
@addisonklinke commented on GitHub (Aug 14, 2022):
Still having trouble with this on
actversion 0.2.30. My repository has this structureThen within
.github/workflows/pull_request_ci.yamlI try to use the actionBut triggering with
actI still getI've tried both with and without the
.yamlextension@KnisterPeter commented on GitHub (Aug 15, 2022):
You need to checkout your repository to use local actions.
@ChristopherHX commented on GitHub (Aug 15, 2022):
Both your repository structure and uses syntax are wrong, this wouldn't work on github.
You have to change it to
EDIT you can also use both
action.yamlandaction.yml@addisonklinke commented on GitHub (Aug 22, 2022):
@KnisterPeter @ChristopherHX thanks for the tips! After adding
actions/checkoutand restructuring the localsetup-env/action.yaml, it is working