New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find local action #307
Comments
My guess is that this line is incorrect: act/pkg/runner/step_context.go Line 52 in 64b8d2a
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. |
Seems to work if you set the reference to the local action from the root of the Github workflow jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Run test action
uses: ./my-actions/action1 Local action ├── /.github
│ └── workflows
└── /my-actions
└── /action1
├── action.yaml
└── Dockerfile |
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. |
Issue is stale and will be closed in 7 days unless there is new activity |
Still having trouble with this on
Then within jobs:
example:
runs-on: ubuntu-latest
steps:
- uses: ./.github/actions/setup-env.yaml But triggering with
I've tried both with and without the |
You need to checkout your repository to use local actions. |
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 |
@KnisterPeter @ChristopherHX thanks for the tips! After adding |
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-job
I get this error:Note that the
init/action.yml
file 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.
The text was updated successfully, but these errors were encountered: