Reputation: 5738
I am trying to run docker-compose up -d --build
from Ubuntu (Windows WSL 2). I have enabled the WSL integration as per the steps listed here. Docker and compose are working from my Ubuntu terminal as shown in the screenshot below but it gives me the error complaining that "Error response from daemon: path ... is mounted on / but it is not a shared mount". How should I resolve this issue?
Upvotes: 0
Views: 4171
Reputation: 5198
Posting this as an answer for easier reading.
As mentioned in the comments, the solution appeared to be removing slashes from volumes as suggested by this similar question and answer:
From this:
volumes:
- ./server/:/usr/src/app/
To this:
volumes:
- ./server:/usr/src/app
Snippet from user's related question here.
Upvotes: 3