pmandayam
(Pmandayam)
August 15, 2015, 10:18pm
1
I am running docker on windows with the docker-machine and Docker Toolbox installation package.
Boot2Docker is now deprecated, btw.
The docs here: https://docs.docker.com/examples/mongodb/ told me to connect to the running mongodb container like:
$ mongo --port 27017 --host 192.168.99.100
But I get this error:
$ mongo --host 192.168.99.100
sh: mongo: command not found
Any ideas?
EDIT 1: I run the container like this:
$ docker run -p 27017:27017 --name mongodb -d myname/repo
sapjpp
(Joe)
August 16, 2015, 12:04am
2
Hi,
This looks like a UNIX problem.
Where is mongo installed? Is the /bin in your PATH?
Confirm that it is, and then try.
Cheers,
Joe
dolphyvn
(Dolphyvn)
August 16, 2015, 2:56pm
3
Yeah, look like you have to check if you at-least have mongo client installed on your docker host. If yes check whether it has execute permission and in PATH ENV.
pmandayam
(Pmandayam)
August 16, 2015, 4:30pm
4
@dolphyvn @sapjpp ahh I see, I have to add it to my path. Thanks to both of you.