You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bind-mounts happen on the daemon side, and default to assuming the path given is a directory. If your daemon is running remotely and doesn't have a file at the given location, and you're using the shorthand form for bind-mounts (<source>:<destination>), the daemon will automatically create the location on the host (which will be a directory), and bind-mount that in the container.
While on macOS, the daemon is also running "remotely" (in a VM) Docker Desktop makes sure that the files you're bind-mounting are present inside the VM before running the container.
Yeah, I think that tracks, except the file exists at the given location. Perhaps linux is having trouble finding the file or with the relative path (./) when dealing with a single file mount?
Moving the file to the some_scripts directory and mounting the directory like this seems to work fine on linux:
I have a
docker-compose.yml
that has a single file mounted as a volume that works fine on MacOS hosts.ie:
However, when I try this on a linux machine, the file is incorrectly mounted as a directory, which breaks my image.
The text was updated successfully, but these errors were encountered: