docker port mapping for consul agent -


i downloaded consul 0.6.3 in linux machine , warpped in docker container. in container running command

consul agent -dev 

it runs , inside container if

$ curl localhost:8500/v1/catalog/nodes 

the output

[{"node":"8f1841ad54bb","address":"172.17.0.163","createindex":3,"modifyindex":4}] 

which perfect.

now in mother machine docker daemon running if docker ps shows correct running container

container id        image        command               status              ports                     names 8f1841ad54bb        myconsul   "/bin/bash"           35 minutes       0.0.0.0:32787->8500/tcp   consul-server   

however if mother machine

# curl localhost:32787/v1/catalog/nodes 

it says

curl: (56) failure when receiving data peer 

though docker mapping seems correct, can tell me issue?


Comments

Popular posts from this blog

java - pagination of xlsx file to XSSFworkbook using apache POI -

Unlimited choices in BASH case statement -

apache - How do I stop my index.php being run twice for every user -