Docker complains that bind source path doesn't exist, but it DOES

I’m trying to start a mysql container with a host directory mounted. I’m running a single-node swarm in Docker for AWS. But I can’t mount a directory…

This is the section of the docker-compose file I’m using:

  • phantomJS on docker containers
  • how to create a docker image/container with same file rights as host user
  • How to debug docker container with PhpStorm
  • Docker Sidekiq Starting - Rails App with Puma
  • How to start railo service in background on the Docker
  • Permissions issue with Docker volumes
  • mysql:
        image: mysql-custom
        volumes:
            - /mysql:/var/lib/mysql
        ports:
            - "3307:3306"
    

    And this is the launch command I’m trying:

    docker stack deploy --compose-file docker-compose.yml stack12
    

    When I launch however, docker swarm rejects the image, saying “invalid mount config for type \”bind\”: bind source path does not exist”. However, /mysql is a valid directory, I can cd to it and everything, so why is docker saying it does not exist?

  • Can not connect to websocket using django-channels , nginx on docker as services
  • Docker - Enable Remote HTTP API with SystemD and “daemon.json”
  • How is docker able to mount a volume from docker client into a docker container running on docker host?
  • docker: structure needs cleaning
  • How to bootstrap a docker container?
  • How to stop docker
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.