Search code examples
dockerdocker-composevirtualboxddevmautic

for ddev-mautic-db Cannot create container for service db: invalid mount config for type "bind": bind source path does not exist


I am trying to setup ddev along docker and docker-compose on Mac OS 10.12.6 by running command inside project folder which is already set up ddev. I am setting up https://github.com/mautic/mautic this project over my local machine.

ddev start

Error I am getting is

ERROR: for ddev-mautic-db  Cannot create container for service db: invalid mount config for type "bind": 
bind source path does not exist: /Library/WebServer/Documents/codebase/mautic/.ddev

ERROR: for db  Cannot create container for service db: invalid mount config for type "bind": 
bind source path does not exist: /Library/WebServer/Documents/codebase/mautic/.ddev
Encountered errors while bringing up the project.' 

I have set up by following command

docker-machine create --driver virtualbox default
$ docker-machine env default
$ eval "$(docker-machine env default)"

Totally new to docker and ddev didn't find answer which can help me to solve.

Any help will be appreciated!


Solution

  • I've never used docker toolbox on the mac, but on Windows with Docker Toolbox, only your home directory is shared by default. It looks like you have the project in /Library/WebServer/Documents, which is not your home directory. I recommend that you either put the project in your home directory or research how to share /Library/Webserver/Documents with Docker Toolbox. I think you'll likely find some answers about this here: https://www.google.com/search?q=docker+toolbox+shared+drives+macos&sxsrf=ALeKk00SOQVEtAU9hFcHPoxV75aJoMcWgQ%3A1621959319429&ei=lyKtYL_OGcqttQaEnI2ABg&oq=docker+toolbox+shared+drives+macos&gs_lcp=Cgdnd3Mtd2l6EAMyBQgAEM0COgcIIxCwAxAnOgcIABBHELADOgYIABAWEB46CAghEBYQHRAeOgcIIRAKEKABOgUIIRCrAlCoc1jsgQFgh4QBaAFwAngAgAHrAogB9AeSAQcxLjUuMC4xmAEAoAEBqgEHZ3dzLXdpesgBCcABAQ&sclient=gws-wiz&ved=0ahUKEwj_9cuoneXwAhXKVs0KHQROA2AQ4dUDCBE&uact=5

    Please note that Docker Toolbox on Mac has never been tried by anybody else to my knowledge. Also note that you can download ancient versions of Docker Desktop from https://docs.docker.com/docker-for-mac/release-notes/