安装node
###下载
wget https://nodejs.org/dist/v10.15.3/node-v10.15.3-linux-x64.tar.xz
### 解压
tar xvf node-v10.15.3-linux-x64.tar.xz
### 剪切
mv node-v10.15.3-linux-x64 /usr/local/node
添加环境变量
cat >> /etc/profile << EOF
## add node
export NODE_HOME=/usr/local/node
export PATH=$PATH:$NODE_HOME/bin
export NODE_PATH=$NODE_HOME/lib/node_modules
EOF
source /etc/profile
安装elasticsearch-head
git clone https://github.com/mobz/elasticsearch-head.git
cd elasticsearch-head
npm install
###若上一步出错,需忽略phantomjs-prebuilt@2.1.16,则执行
npm install phantomjs-prebuilt@2.1.16 --ignore-scripts
## 修改es地址为实际地址
_site/app.js
### 启动
npm run start