Home > Mobile >  Error when running a container using --name flag
Error when running a container using --name flag

Time:02-15

when trying to run docker with a container name, I get the following error (on macOS)

~$ docker run -it myifort --name cont 
docker: Error response from daemon: OCI runtime create failed: container_linux.go:380: starting container process caused: exec: "--name": executable file not found in $PATH: unknown.
ERRO[0000] error waiting for container: context canceled

Without the --name flag everything works as expected.

CodePudding user response:

I'm not sure what you named your build image but you would not use -it in the run command so just try docker run myifort --name cont

  • Related