I am trying to start the mysql container with the host directory installed. I am running a single swarm in Docker for AWS. But I can not install the directory ...
This is the section of the file that I am using:
mysql:
image: mysql-custom
volumes:
- /mysql:/var/lib/mysql
ports:
- "3307:3306"
And this is the start command that I am trying to execute:
docker stack deploy --compose-file docker-compose.yml stack12
When I start, however, the docker swarm rejects the image, saying "the mount configuration is incorrect for type \" bind \ ": linking the source path does not exist." However, / mysql is a valid directory, I can write everything to it, so why does the docker say that it does not exist?
source
share