`
can_do
  • 浏览: 263579 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

【Do家】安装(部署)API-Gateway Kong的详细步骤

阅读更多
[0/4]
openresty version =>1.13.6.1
KongServer version =>v0.13.1
KongDashboard =>v0.3.3.0
PostgreSQL => 10.1 => Schema:kong || User:kong
using installed_ware_of_kong_20180927.zip
[1/4] install node and npm to setting npm for specified vesion
# xz -d node-v8.11.3-linux-x64.tar.xz

# tar -xvf ./node-v8.11.3-linux-x64.tar

# vim /etc/profile
//////////begin///////
export NODE_HOME=/opt/node

export PATH=${NODE_HOME}/bin/:${PATH}
//////////end/////////

# source /etc/profile

[2/4] create kong account
Note:pg's release version is mandatory
PostgreSQL 10.1 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18), 64-bit =>ok
PostgreSQL 10beta2 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-18), 64-bit => NOT ok
1> create user kong with password 'kong@yourOwnerPwd';
   or =>alter user kong with password 'kong@yourOwnerPwd';
2> CREATE DATABASE kong OWNER kong;
3> grant all privileges on database kong to kong;

[3/4]install kong
# yum install -y perl-Time-HiRes.x86_64
# rpm -Uvh  kong-community-edition-0.13.1.el6.noarch.rpm
  => OR rpm -Uvh --force --nodeps kong-community-edition-0.13.1.el6.noarch.rpm
# cp /etc/kong/kong.conf.default /etc/kong/kong.conf

# vim /etc/kong/kong.conf => configure postgresql port and password

# /usr/local/bin/kong migrations up [-c /usr/local/etc/kong/kong.conf]

# /usr/local/bin/kong start [-c /usr/local/etc/kong/kong.conf]

[4/4] install and start kong-dashboard
# npm config set strict-ssl false
# npm install -g kong-dashboard@3.3.0
/opt/node/bin/kong-dashboard -> /opt/node/lib/node_modules/kong-dashboard/bin/kong-dashboard.js
+ kong-dashboard@3.3.0
added 185 packages in 23.922s

[Last]
1> modify logs directory
mkdir -p /data/kong/logs/
vim /etc/kong/kong.conf
2> modify logs format

【温馨提示】
如果您觉得满意,可以选择支持下,您的支持是我最大的动力:







分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics