docker install consul

docker install consul

1.1 Download image

$ docker pull consul

1.2 Create a configuration file

$ mkdir -p /data/consul/{
    
    conf,data}

1.2 Run the container, map to the host, and mount the Volume

$ docker run \
--name consul \
-p 8500:8500 \
-v /data/consul/conf/:/consul/conf/ \
-v /data/consul/data/:/consul/data/ \
-d consul

1.3 Access

http://localhost:8500

Guess you like

Origin blog.csdn.net/jinian2016/article/details/112986326