spring:
cloud:
gateway:
routes:
- id: server-user
uri: lb://server-user
predicates:
- Path=/api/user/**
- DocName=用户
filters:
- StripPrefix=2
- id: server-basic
uri: lb://server-basic
predicates:
- Path=/api/basic/**
- DocName=基础
filters:
- StripPrefix=2
# ws表示websocket的转发
- id: nocas-websocket
uri: lb:ws://server-websocket
predicates:
- Path=/serlb/ws/**
- DocName=noSwagger
filters:
- StripPrefix=2
default-filters:
# - StripPrefix=2
# - RewritePath=/api/(?<segment>.*), /$\{segment}
- name: AuthFilter
args:
excludePatterns: #不做权限校验的路径
- /api/user/userInfo/login
# - /socket/**
- /api/basic/openFeign/test01
- /api/test/test01
- /serlb/ws/socket/**