Bick
Bick

Reputation: 18521

Running consul in a container with UI

Following the official documentation I am running

docker run -d --name=dev-consul -e CONSUL_BIND_INTERFACE=eth0 consul -ui -p 8500:8500

I added -ui and -p 8500:8500 to enable consul UI.
But I cant really browse

http://localhost:8500/ui/

Or telnet 127.0.0.1 8500.

How can I browse consul UI when I am running it in docker?

Upvotes: 3

Views: 1561

Answers (2)

Abdelhafid
Abdelhafid

Reputation: 919

Try this command :

docker run --name consul -p 8500:8500 consul agent -dev -ui -client=0.0.0.0 -bind=0.0.0.0

Upvotes: 5

D. Vinson
D. Vinson

Reputation: 1158

You are binding to the eth0 so you need to use the ip address for eth0.

docker inspect dev-consul

Get the ip address and use the ip with the port like:

172.17.0.2:8500

Upvotes: 0

Related Questions