用户信息传到service
This commit is contained in:
@@ -1,10 +1,21 @@
|
||||
plugin_configs:
|
||||
- id: 1
|
||||
plugins:
|
||||
serverless-pre-function:
|
||||
phase: access
|
||||
functions:
|
||||
- |
|
||||
local f = assert(loadfile("/usr/local/apisix/auth.lua"))
|
||||
local mod = f()
|
||||
return mod.access
|
||||
|
||||
routes:
|
||||
- id: bff
|
||||
name: bff
|
||||
- id: bff-no-auth
|
||||
name: bff-no-auth
|
||||
priority: 100
|
||||
uris:
|
||||
- /admin/*
|
||||
- /api/*
|
||||
- /app/*
|
||||
- /api/v3/login
|
||||
- /admin/v3/login
|
||||
methods:
|
||||
- GET
|
||||
- POST
|
||||
@@ -14,4 +25,21 @@ routes:
|
||||
type: roundrobin
|
||||
nodes:
|
||||
"bff:10000": 1
|
||||
#END
|
||||
|
||||
- id: bff
|
||||
name: bff
|
||||
priority: 10
|
||||
uris:
|
||||
- /admin/*
|
||||
- /api/*
|
||||
methods:
|
||||
- GET
|
||||
- PUT
|
||||
- POST
|
||||
- OPTIONS
|
||||
plugin_config_id: 1
|
||||
upstream:
|
||||
type: roundrobin
|
||||
nodes:
|
||||
"bff:10000": 1
|
||||
#END
|
||||
Reference in New Issue
Block a user