上一篇搭建了es服务,为了方便es的管理,可以安装搭建es web管理工具服务,这里选取elastic. Head。
- 拉取镜像
docker pull mobz/elasticsearch-head:5
下载完成后,检测本地镜像:
docker images | grep elastic
![e76b1d8ebb0b5c31f42d484f730fa0eb.png](https://i-blog.csdnimg.cn/blog_migrate/81af1e3e0d6b39fa31c1185e9853f57c.jpeg)
检测本地镜像
- 启动容器
docker run -d --name head -p 9100:9100 mobz/elasticsearch-head:5
启动后,检测es服务
docker ps -a | grep head
![433eccd192dfe39e5a635eb5c56426e6.png](https://i-blog.csdnimg.cn/blog_migrate/8fe40625ca0b204ee002bae0e4068d3a.jpeg)
Head 容器
ps:注意es需要配置允许跨域请求:
docker exec -it es5.6 /bin/bash vi config/elasticsearch.yml 添加: # 加入跨域配置 http.cors.enabled: true http.cors.allow-origin: "*"
保存重启,
docker restart es5.6
- 启动浏览器
![04b447547f02051c90496d845947af91.png](https://i-blog.csdnimg.cn/blog_migrate/5470b80067317d5e02b6244305236aa8.jpeg)
Head 使用