Reputation: 353
I am trying to pull a docker image using the following command. It was suggested that I run this as a guide for docker config at my workplace.
Tried removing the -d
out of the command, but now I get same error but with -name
instead. I am using a Mac and I run the command on the terminal.
docker pull mysql/mysql-server:5.7docker run -d --name=dev-mysql -p3306:3306 -e MYSQL_ROOT_PASSWORD= -e MYSQL_ROOT_HOST=% mysql/mysql-server:5.7 --secure-file-priv=""
I expect the image to be downloaded. But instead I get the mentioned error.
Upvotes: 3
Views: 9614
Reputation: 5016
Your command is two separated commands.
Try this (it will download the image):
docker pull mysql/mysql-server:5.7
Then (it will run the container):
docker run -d --name=dev-mysql -p3306:3306 -e MYSQL_ROOT_PASSWORD= -e MYSQL_ROOT_HOST=% mysql/mysql-server:5.7 --secure-file-priv=""
Upvotes: 5