-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
Bind Mounts on windows not working #100
Comments
Nice! This helped me complete the tutorial on Windows 10.
|
Glad I found this thread. I too have the same problem. Not sure if it is something new with WSL2. Docker did first accept the new command syntax |
Awsome.. thanks a lot.. was stuck all day on this.. |
I had to be in the right directory (where I downloaded and unzipped the app). |
For me, this worked: The important bits were:
|
confirmed. since "${PWD}" is basically the command to get the current directory path, you need to be inside of the proper directory to the correct path to run the command! |
Hopefully they will update the docs this year. #184 |
If you use the docker desktop app, you can click on the container name and it will try to create the container and show you any errors. |
Hi all! Apologies for the delay in responding to this issue. The tutorial has gone through several improvements since this issue was created, some of which I anticipate would have resolved this issue. In addition, there are a few answers that have been posted here already. Therefore, I'm going to go ahead and close it. If you have future questions or issues, feel free to create a new issue and we'll be happy to help out (and will respond much more quickly too!). Thanks all! |
I know this closed, but for others after me--the issue I ran into was |
I'm trying to understand why i cant execute this command, i'm currently inside getting-started\app (on Windows) and i get errors:
docker run -dp 3000:3000 \ -w /app -v "$(pwd):/app" \ node:12-alpine \ sh -c "yarn install && yarn run dev"
This opens a message saying docker wants to access: C:\PATH\getting-started\app;C (with the weird ;C at the end)
If i change the code in this way it goes away:
-w //app -v "$(pwd)://app" \
it starts a container which gets closed immediatly with an error:
error Couldn't find a package.json file in "/app"
I don't understand why, is the dockerfile or the package.json missplaced? I tried to look at other similar issues on github but i was unable to solve my problem.
Thank you!
UPDATE:
Asked a friend, seems like there is a problem with paths that has to be written not in windows style:
So from getting-started/app i did:
docker run -dp 3000:3000
-w //app -v "//c/Users/blabla/app_test/getting-started":/app
node:12-alpine
sh -c "yarn install && yarn run dev"
note the -v has the : in which the host directory is written in a Linux format
note: if in the -w i would put only: -w /app it would trigger an error:
docker: Error response from daemon: the working directory 'C:/Program Files/Git/app' is invalid, it needs to be an absolute path.
(With the weird git path)
The text was updated successfully, but these errors were encountered: