参考:https://www.cnblogs.com/duanxz/p/10364783.html
1、已经安装好postgresql,可以参考这个博客
https://www.cnblogs.com/stulzq/p/7766409.html
2、碰到的问题
2.1 如果报错错误: 函数 to_regclass(unknown) 不存在 (12)
参考 https://www.lijiaocn.com/%E9%97%AE%E9%A2%98/2018/09/29/kong-usage-problem-and-solution.html, postgresql版本升级就可以。sudo yum install https://download.postgresql.org/pub/repos/yum/10/redhat/rhel-7-x86_64/pgdg-centos10-10-1.noarch.rpm#sudo yum install https://download.postgresql.org/pub/repos/yum/9.6/redhat/rhel-7-x86_64/pgdg-centos96-9.6-3.noarch.rpmkong migrations bootstrap
2.2 kong migrations up -c /etc/kong/kong.conf.default 执行这个的时候"Ident 认证失败"可以用参考网址的方法我用的是postgresql10版本,sudo vim /var/lib/pgsql/10/data/pg_hba.conf修改对应的地方为password2.3 kong start -c /etc/kong/kong.conf --vv执行这个的时候报没有权限,就用sudo执行sudo /usr/local/bin/kong start -c /etc/kong/kong.conf --vv
2019/10/22 17:38:44 [debug] starting nginx: /usr/local/openresty/nginx/sbin/nginx -p /usr/local/kong -c nginx.conf
2019/10/22 17:38:47 [debug] nginx started
2019/10/22 17:38:47 [info] Kong started
成功了! 本人qq: 575654643