docker_files icon indicating copy to clipboard operation
docker_files copied to clipboard

Cannot start service: b'Mounts denied

Open marktopper opened this issue 6 years ago • 6 comments

~/Sites $ git clone https://github.com/tellform/docker_files
Cloning into 'docker_files'...
remote: Counting objects: 61, done.
remote: Total 61 (delta 0), reused 0 (delta 0), pack-reused 61
Unpacking objects: 100% (61/61), done.
~/Sites $ cd docker_files/
~/Sites/docker_files (master) $ cp .env.dist .env
~/Sites/docker_files (master) $ docker-compose up -d
Creating network "dockerfiles_default" with the default driver
Creating dockerfiles_web_1 ...
Creating dockerfiles_redis_1 ...
Creating dockerfiles_mongo_1 ... error

Creating dockerfiles_redis_1 ... error
s from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'
Creating dockerfiles_web_1   ... error
ERROR: for dockerfiles_redis_1  Cannot start service redis: b'Mounts denied: \r\nThe path /opt/tellform_data/redis\r\nis not shared from OS X and is not known to Docker.\r\nYou can configure shared paths from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'

ERROR: for dockerfiles_web_1  Cannot start service web: b'Mounts denied: \r\nThe path /opt/tellform_data/certs\r\nis not shared from OS X and is not known to Docker.\r\nYou can configure shared paths from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'

ERROR: for mongo  Cannot start service mongo: b'Mounts denied: \r\nThe path /opt/tellform_data/mongo\r\nis not shared from OS X and is not known to Docker.\r\nYou can configure shared paths from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'

ERROR: for redis  Cannot start service redis: b'Mounts denied: \r\nThe path /opt/tellform_data/redis\r\nis not shared from OS X and is not known to Docker.\r\nYou can configure shared paths from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'

ERROR: for web  Cannot start service web: b'Mounts denied: \r\nThe path /opt/tellform_data/certs\r\nis not shared from OS X and is not known to Docker.\r\nYou can configure shared paths from Docker -> Preferences... -> File Sharing.\r\nSee https://docs.docker.com/docker-for-mac/osxfs/#namespaces for more info.\r\n.'
ERROR: Encountered errors while bringing up the project.

Any idea how to solve this?

marktopper avatar Apr 18 '18 11:04 marktopper

@marktopper

  1. Make new directories /opt/tellform_data/certs and /opt/tellform_data/mongo
  2. Go to Docker > Preferences > File Sharing
  3. Add /opt/tellform_data/certs and /opt/tellform_data/mongo
  4. Restart docker

These works for me.

spkjess avatar Oct 20 '18 08:10 spkjess

Also not working for me, this issue is probably better suited for https://github.com/docker/for-mac

Kielan avatar Nov 13 '18 23:11 Kielan

Guys Steps to solve

  1. Remove laradock dirc from your project 2.Clone laradock from https://laradock.io and Run container commands to install required containers.

That's all everything should work.

sandeepchowdary7 avatar Apr 02 '19 02:04 sandeepchowdary7

Had very similar issue (with docker desktop for mac), restarting docker fixed it.. \o/

danwild avatar Oct 17 '19 05:10 danwild

@marktopper

  1. Make new directories /opt/tellform_data/certs and /opt/tellform_data/mongo
  2. Go to Docker > Preferences > File Sharing
  3. Add /opt/tellform_data/certs and /opt/tellform_data/mongo
  4. Restart docker

These works for me.

And don't forget to mention to "chown -R /opt/tellform_data" to the user running docker desktop. Otherwise mongodb will start complaining about lack of permissions... :)

davidem avatar Nov 14 '19 22:11 davidem

your mounting the container to a directory that doesn't exist

byteab avatar Jun 04 '20 08:06 byteab