ElasticSearch 6.x head插件安装

一、下载node.js

yum install -y nodejs

 二、安装npm

npm install -g cnpm --registry=https://registry.npm.taobao.org

###如果抱错   npm: relocation error: npm: symbol SSL_set_cert_cb, version libssl.so.10 not defined in file libssl.so.10 with link time reference

##就升级openssl
yum update openssl

  

三、安装grunt

npm install -g grunt

 

四、下载head插件源码

wget https://github.com/mobz/elasticsearch-head/archive/master.zip
unzip master.zip

  

五、下载依赖

###进入elasticsearch-head-master目录,执行下面命令
npm install

  

6.配置 ElasticSearch,使得HTTP对外提供服务

vi config/elasticsearch.yml
# 增加新的参数,这样head插件可以访问es。设置参数的时候:后面要有空格
http.cors.enabled: true
http.cors.allow-origin: "*"

  

7.修改Head插件配置文件

 vim Gruntfile.js 

###到connect:server,添加hostname一项

  ElasticSearch 6.x head插件安装

8.启动head

grunt server

ElasticSearch 6.x head插件安装

9.浏览器访问

ElasticSearch 6.x head插件安装

上一篇:容器网络


下一篇:PhpStorm+PhpStudy+xdebug 配置图解