微服务 服务发现&服务注册 consul的安装和配置

注册中心功能   

1 健康检查

2 配置管理

3 稳定性

4 支持分布式 

拉取叫发现  上报叫注册

产品选型

 https://github.com/hashicorp/consul  进入使用

拉取

docker run -d -p 8500:8500 -p 8300:8300 -p 8301:8301 -p 8302:8302 -p 8600:8600/udp consul consul agent -dev -client=0.0.0.0 

http://10.1.1.246:8500/  web管理页面 端口为8500

安装dig命令   yum install bing-utils

consul提供dns功能,可以让我们通过 可以通过dig命令行来测试,consul默认的dns端口是8600

dig @10.1.1.246 -p 8600 consul.service.consul SRV

猜你喜欢

转载自blog.csdn.net/pzl_pzl/article/details/130952877