mongo icon indicating copy to clipboard operation
mongo copied to clipboard

Cannot find the config file

Open JaxLgj opened this issue 9 years ago • 2 comments

When I run the command docker run --rm --name mongoc1 -v mongoconfig1:C:\data\configdb\ -d mongo -f "C:\data\configdb\mongo.cfg"

get error "docker: Error response from daemon: container 1e9ca3e5f31970d2f0ab18cc7422831813e9ccc580d196a14e372bff3e9e30bc encountered an error during CreateProcess: failure in a Windows system call: The system cannot find the file specified."

default

JaxLgj avatar Oct 10 '17 09:10 JaxLgj

Indeed, that's by design -- on Windows, we cannot easily support the same sort of entrypoint behavior we have in the Linux variants, so you'll have to include mongod in your command:

C:> docker run --rm --name mongoc1 -v mongoconfig1:C:\data\configdb\ -d mongo mongod -f "C:\data\configdb\mongo.cfg"

tianon avatar Oct 10 '17 16:10 tianon

@tianon Ohh, thank you for your help.

JaxLgj avatar Oct 12 '17 01:10 JaxLgj