码迷,mamicode.com
首页 > 数据库 > 详细

kong db_less 配置demo

时间:2019-10-24 10:20:50      阅读:178      评论:0      收藏:0      [点我收藏+]

标签:out   ant   less   测试   加载   text   url   use   route   

/etc/kong/kong.yml

services:

consumers:

  • username: my-user
    keyauth_credentials:
    • key: my-key

plugins:

  • name: syslog
    consumer: my-user
    service: my-service

加载:
kong reload -c /etc/kong/kong.conf
测试:
curl -i -X GET --url "http://192.168.8.106:8000/aa/query?type=yuantong&postid=11111111111" --header "apikey:my-key" --header "host:www.kuaidi100.com"
返回:
{"message":"ok","nu":"11111111111","ischeck":"1","com":"yuantong","status":"200","condition":"F00","state":"3","data":[{"time":"2019-10-05 16:51:59","context":"查无结果","ftime":"2019-10-05 16:51:59"}]}

kong db_less 配置demo

标签:out   ant   less   测试   加载   text   url   use   route   

原文地址:https://blog.51cto.com/204222/2444821

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!