es5以上版本安装head需要安装node和grunt(之前的直接用plugin命令即可安装)
1、https://nodejs.org/en/download/ node下载地址
下载完成后直接安装。
2、进入cmd,通过node -v命令查看版本,确定安装成功
3、通过npm install -g grunt-cli安装grunt
4、执行grunt -version查看是否安装成功,会显示安装的版本号
5、开始安装head
进入elasticSearch的文件目录,找到config目录,编辑elasticsearch.yml文件,在文件中加入以下四句:
http.cors.enabled: true
http.cors.allow-origin: "*"
node.master: true
node.data: true
重启elasticSearch
在https://github.com/mobz/elasticsearch-head中下载head插件,选择下载zip
解压,进入该文件夹,修改Gruntfile.js 在对应的位置加上hostname:'*'
在elasticsearch-head-master 下执行npm install 安装完成后执行grunt server 或者npm run start 运行head插件。