ocelot.json 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. {
  2. "GlobalConfiguration": {
  3. "BaseUrl": "http://127.0.0.1:5001"
  4. },
  5. "Routes": [
  6. // API:登录(不验证)
  7. {
  8. "DownstreamPathTemplate": "/api/login/{url}",
  9. "DownstreamScheme": "http",
  10. "DownstreamHostAndPorts": [
  11. {
  12. "Host": "127.0.0.1",
  13. "Port": "5002"
  14. }
  15. ],
  16. "UpstreamPathTemplate": "/api/login/{url}",
  17. "UpstreamHttpMethod": [ "Get", "Post" ]
  18. },
  19. // API:授权信息
  20. {
  21. "DownstreamPathTemplate": "/api/{url}",
  22. "DownstreamScheme": "http",
  23. "DownstreamHostAndPorts": [
  24. {
  25. "Host": "127.0.0.1",
  26. "Port": "5002"
  27. }
  28. ],
  29. "UpstreamPathTemplate": "/api/auth/{url}",
  30. "UpstreamHttpMethod": [ "Get", "Post" ],
  31. "AuthenticationOptions": {
  32. "AuthenticationProviderKey": "YZT",
  33. "AllowedScopes": []
  34. }
  35. },
  36. // API:一张图应用
  37. {
  38. "DownstreamPathTemplate": "/api/{url}",
  39. "DownstreamScheme": "http",
  40. "DownstreamHostAndPorts": [
  41. {
  42. "Host": "127.0.0.1",
  43. "Port": "5003"
  44. }
  45. ],
  46. "UpstreamPathTemplate": "/api/yzt/{url}",
  47. "UpstreamHttpMethod": [ "Get", "Post" ],
  48. "AuthenticationOptions": {
  49. "AuthenticationProviderKey": "YZT",
  50. "AllowedScopes": []
  51. }
  52. },
  53. // API:成果管理
  54. {
  55. "DownstreamPathTemplate": "/api/{url}",
  56. "DownstreamScheme": "http",
  57. "DownstreamHostAndPorts": [
  58. {
  59. "Host": "127.0.0.1",
  60. "Port": "5004"
  61. }
  62. ],
  63. "UpstreamPathTemplate": "/api/cggl/{url}",
  64. "UpstreamHttpMethod": [ "Get", "Post" ],
  65. "LoadBalancer": "RoundRobin",
  66. "AuthenticationOptions": {
  67. "AuthenticationProviderKey": "YZT",
  68. "AllowedScopes": []
  69. }
  70. },
  71. // API:规划实施
  72. {
  73. "DownstreamPathTemplate": "/api/{url}",
  74. "DownstreamScheme": "http",
  75. "DownstreamHostAndPorts": [
  76. {
  77. "Host": "127.0.0.1",
  78. "Port": "5005"
  79. }
  80. ],
  81. "UpstreamPathTemplate": "/api/ghss/{url}",
  82. "UpstreamHttpMethod": [ "Get", "Post" ],
  83. "AuthenticationOptions": {
  84. "AuthenticationProviderKey": "YZT",
  85. "AllowedScopes": []
  86. }
  87. },
  88. // API:分析评价
  89. {
  90. "DownstreamPathTemplate": "/api/{url}",
  91. "DownstreamScheme": "http",
  92. "DownstreamHostAndPorts": [
  93. {
  94. "Host": "127.0.0.1",
  95. "Port": "5006"
  96. }
  97. ],
  98. "UpstreamPathTemplate": "/api/fxpj/{url}",
  99. "UpstreamHttpMethod": [ "Get", "Post" ],
  100. "AuthenticationOptions": {
  101. "AuthenticationProviderKey": "YZT",
  102. "AllowedScopes": []
  103. }
  104. },
  105. // API:文件
  106. {
  107. "DownstreamPathTemplate": "/files/{url}",
  108. "DownstreamScheme": "http",
  109. "DownstreamHostAndPorts": [
  110. {
  111. "Host": "127.0.0.1",
  112. "Port": "5004"
  113. }
  114. ],
  115. "UpstreamPathTemplate": "/files/{url}",
  116. "UpstreamHttpMethod": [ "Get", "Post" ]
  117. },
  118. // API:后台管理
  119. {
  120. "DownstreamPathTemplate": "/api/{url}",
  121. "DownstreamScheme": "http",
  122. "DownstreamHostAndPorts": [
  123. {
  124. "Host": "127.0.0.1",
  125. "Port": "5007"
  126. }
  127. ],
  128. "UpstreamPathTemplate": "/api/mgr/{url}",
  129. "UpstreamHttpMethod": [ "Get", "Post" ],
  130. "AuthenticationOptions": {
  131. "AuthenticationProviderKey": "YZT",
  132. "AllowedScopes": []
  133. }
  134. }
  135. ]
  136. }