-
Notifications
You must be signed in to change notification settings - Fork 61.3k
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
Working Directory with custom images #37027
Comments
Thanks for opening this issue. A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines. |
Thanks for opening an issue! We've triaged this issue for technical review by a subject matter expert 👀 |
@richseviora Thank you for opening this issue! I'll get this triaged for review. ✨ Our team will provide feedback regarding best next steps. Thanks for your patience! |
@richseviora While we're waiting for an SME review, one of the members of the team found this article and wondered if you had read it/if it could help with the problem you're encountering. 💛 |
Hi @Sharra-writes! Thanks for that link! This feels related to the issue I encountered. I didn't find it when I first went looking for this issue. ... actually, on second thought, I think this article is definitely related to my issue and could have the same root cause, but I think the presentation is a bit different. Which I think is actually a really helpful distinction, at least it is for me and my mental model :) The article you linked to is written in the context of creating a custom GH action, whereas I'm trying to use a prebuilt image here in a GH workflow. So some of that article's instructions appear to be relevant (like the
I was going to suggest linking to that article, but given that the context is different I'm left wondering whether that's the right thing to do. What do you think? |
Code of Conduct
What article on docs.github.com is affected?
https://docs.github.com/en/actions/writing-workflows/choosing-where-your-workflow-runs/running-jobs-in-a-container
What part(s) of the article would you like to see updated?
When using a custom image, I've observed that GH Actions appears to be setting the container's work directory to its own custom directory. In my case it's
__w/server/server
. Therefore, any bash command I would've ran as-is successfully fails until I set theworking-directory
option to the correct value.I don't know exactly how that value is being set, though it certainly appears to align with the volume paths captured here.
Additional information
I can confirm that setting the
working-directory
fixed my problem, but I don't know what's causing the issue and therefore what conditions it presents itself in.The text was updated successfully, but these errors were encountered: