初始化
This commit is contained in:
138
pqs-gateway/src/main/resources/bootstrap.yml
Normal file
138
pqs-gateway/src/main/resources/bootstrap.yml
Normal file
@@ -0,0 +1,138 @@
|
||||
#当前服务的基本信息
|
||||
microservice:
|
||||
ename: @artifactId@
|
||||
name: "@name@"
|
||||
version: @version@
|
||||
sentinel:
|
||||
url: @sentinel.url@
|
||||
gateway:
|
||||
url: @gateway.url@
|
||||
server:
|
||||
port: 10215
|
||||
spring:
|
||||
application:
|
||||
name: @artifactId@
|
||||
main:
|
||||
allow-bean-definition-overriding: true
|
||||
#nacos注册中心以及配置中心的指定
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
server-addr: @nacos.url@
|
||||
namespace: @nacos.namespace@
|
||||
config:
|
||||
server-addr: @nacos.url@
|
||||
namespace: @nacos.namespace@
|
||||
file-extension: yaml
|
||||
shared-configs:
|
||||
- data-id: share-config.yaml
|
||||
refresh: true
|
||||
- data-Id: share-config-datasource-db.yaml
|
||||
refresh: true
|
||||
gateway:
|
||||
globalcors:
|
||||
corsConfigurations:
|
||||
'[/**]':
|
||||
allowCredentials: true
|
||||
exposedHeaders: "Content-Disposition,Content-Type,Cache-Control"
|
||||
allowedHeaders: "*"
|
||||
allowedOrigins: "*"
|
||||
allowedMethods: "*"
|
||||
discovery:
|
||||
locator:
|
||||
# 开启自动代理 (自动装载从配置中心serviceId)
|
||||
enabled: true
|
||||
# 服务id为true --> 这样小写服务就可访问了
|
||||
lower-case-service-id: true
|
||||
routes:
|
||||
- id: pqs-auth
|
||||
uri: lb://pqs-auth
|
||||
predicates:
|
||||
- Path=/pqs-auth/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: user-boot
|
||||
uri: lb://user-boot
|
||||
predicates:
|
||||
- Path=/user-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: device-boot
|
||||
uri: lb://device-boot
|
||||
predicates:
|
||||
- Path=/device-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: system-boot
|
||||
uri: lb://system-boot
|
||||
predicates:
|
||||
- Path=/system-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: harmonic-boot
|
||||
uri: lb://harmonic-boot
|
||||
predicates:
|
||||
- Path=/harmonic-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: energy-boot
|
||||
uri: lb://energy-boot
|
||||
predicates:
|
||||
- Path=/energy-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
- id: event-boot
|
||||
uri: lb://event-boot
|
||||
predicates:
|
||||
- Path=/event-boot/**
|
||||
filters:
|
||||
- SwaggerHeaderFilter
|
||||
- StripPrefix=1
|
||||
|
||||
#项目日志的配置
|
||||
logging:
|
||||
config: http://@nacos.url@/nacos/v1/cs/configs?tenant=@nacos.namespace@&group=DEFAULT_GROUP&dataId=logback.xml
|
||||
level:
|
||||
root: info
|
||||
|
||||
whitelist:
|
||||
urls:
|
||||
- /
|
||||
- /user-boot/user/generateSm2Key
|
||||
- /user-boot/theme/getTheme
|
||||
- /user-boot/user/updateFirstPassword
|
||||
- /pqs-auth/oauth/logout
|
||||
- /pqs-auth/oauth/token
|
||||
- /pqs-auth/auth/getImgCode
|
||||
- /pqs-auth/oauth/getPublicKey
|
||||
- /pqs-auth/judgeToken/guangZhou
|
||||
- /webjars/**
|
||||
- /doc.html
|
||||
- /swagger-resources/**
|
||||
- /*/v2/api-docs
|
||||
- /favicon.ico
|
||||
- /device-boot/**
|
||||
- /system-boot/**
|
||||
- /harmonic-boot/**
|
||||
- /energy-boot/**
|
||||
- /event-boot/**
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
7
pqs-gateway/src/main/resources/public.key
Normal file
7
pqs-gateway/src/main/resources/public.key
Normal file
@@ -0,0 +1,7 @@
|
||||
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAn0GHes2u9gE0rAS3S0zM
|
||||
20gJJdRr1yKPGs/yp7cTuz2wAYTsFdO2WKx+GS+DyHgBznJsbPS1KLpyAEJLRaGe
|
||||
xz7T6GPK7yJExxU2eq0gmOLwFa9NS8gtsKpfpAc4C4J/Vc8S6X4vDEEQBdREM+lP
|
||||
fmM4+694ev2+4hP0BbropMMrZXx49GxubmqGK1Ka2EUaHWrEG4Ik5ukQyYvNf8Ns
|
||||
6KcaIUP7hHoha/z5cZkjFOOpXBGwx3AQvkuaMkhtOnrMBvLmmiP4TXErnJPXPz8s
|
||||
xfeJXoz8T9aS+Dnvcpogqye2nam/CReLMikTXCPDDVyyT6sVNWVBfJZ/BPCR9gI1
|
||||
3wIDAQAB
|
||||
Reference in New Issue
Block a user