服务打包初步结构

This commit is contained in:
2026-01-02 14:56:14 +08:00
parent 19026c1b30
commit 89bc8bf1d4
77 changed files with 5290 additions and 2070 deletions

View File

@@ -1,117 +0,0 @@
# ================== Server ==================
server:
port: 8088
# servlet:
# context-path: /urban-lifeline/workcase
# ================== Auth ====================
auth:
enabled: true
gate-way: true
whitelist:
- /swagger-ui/**
- /swagger-ui.html
- /v3/api-docs/**
- /webjars/**
- /favicon.ico
- /error
- /actuator/health
- /actuator/info
# 微信客服回调接口(无需鉴权)
- /workcase/chat/kefu/callback
# CRM回调接口无需鉴权但需签名验证
- /workcase/receive/crm
security:
aes:
# AES-256 密钥Base64编码必须与所有服务保持一致
# 警告:这是开发环境密钥,生产环境请使用密钥管理系统
secret-key: MTIzNDU2Nzg5MDEyMzQ1Njc4OTAxMjM0NTY3ODkwMTI=
# ================== Spring ==================
spring:
application:
name: workcase-service
# 文件上传配置
servlet:
multipart:
enabled: true
max-file-size: 500MB
max-request-size: 500MB
# ================== Spring Cloud Nacos ==================
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
namespace: dev
group: DEFAULT_GROUP
# ================== DataSource ==================
datasource:
url: jdbc:postgresql://127.0.0.1:5432/urban_lifeline
username: postgres
password: postgres
driver-class-name: org.postgresql.Driver
# ================== Redis ==================
data:
redis:
host: 127.0.0.1
port: 6379
database: 0
# password: ""
# ================== SpringDoc ==================
springdoc:
api-docs:
enabled: true
path: /v3/api-docs
swagger-ui:
enabled: true
path: /swagger-ui.html
group-configs:
- group: 'default'
display-name: '工单服务 API'
paths-to-match: '/**'
# ================== Dubbo + Nacos ==================
dubbo:
application:
name: urban-lifeline-workcase
qos-enable: false
protocol:
payload: 110100480
name: dubbo
port: -1
registry:
address: nacos://127.0.0.1:8848
scan:
base-packages: org.xyzh.workcase.service.impl
# ================== MyBatis ==================
mybatis-plus:
mapper-locations: classpath:mapper/**/*.xml
type-aliases-package: org.xyzh.common.dto, org.xyzh.api
logging:
config: classpath:log4j2.xml
charset:
console: UTF-8
file: UTF-8
level:
org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping: TRACE
# ================== Jitsi Meet 视频会议配置 ==================
jitsi:
app:
# 应用ID必须与Docker配置中的JWT_APP_ID一致
id: urbanLifeline
# JWT密钥必须与Docker配置中的JWT_APP_SECRET一致
# 警告:生产环境请修改为强随机字符串,并妥善保管
# 注意HS256算法要求密钥长度至少32字节256 bits
secret: urbanLifeline-jitsi-secret-key-2025-production-safe-hs256
server:
# Jitsi Meet服务器地址独立子域名
url: https://org.xyzh.yslg.jitsi
token:
# JWT Token有效期毫秒- 默认2小时
expiration: 7200000

View File

@@ -1,10 +1,17 @@
# ================== Server ==================
# ================== Workcase 工单服务配置 ==================
server:
port: 8188
# servlet:
# context-path: /urban-lifeline/workcase # 微服务架构下context-path由Gateway管理
port: 8088
# ================== Auth ====================
spring:
application:
name: workcase-service
servlet:
multipart:
enabled: true
max-file-size: 500MB
max-request-size: 500MB
# ================== Auth ==================
auth:
enabled: true
gateway-mode: true
@@ -17,81 +24,32 @@ auth:
- /error
- /actuator/health
- /actuator/info
# 微信客服回调接口(无需鉴权)
- /workcase/chat/kefu/callback
# CRM回调接口无需鉴权但需签名验证
- /workcase/receive/crm
security:
aes:
# AES-256 密钥Base64编码必须与所有服务保持一致
# 警告:这是开发环境密钥,生产环境请使用密钥管理系统
secret-key: MTIzNDU2Nzg5MDEyMzQ1Njc4OTAxMjM0NTY3ODkwMTI=
# ================== Spring ==================
spring:
application:
name: workcase-service
# ================== Spring Cloud Nacos ==================
cloud:
nacos:
discovery:
server-addr: 127.0.0.1:8848
namespace: dev
group: DEFAULT_GROUP
# ================== DataSource ==================
datasource:
url: jdbc:postgresql://127.0.0.1:5432/urban_lifeline
username: postgres
password: postgres
driver-class-name: org.postgresql.Driver
# ================== Redis ==================
data:
redis:
host: 127.0.0.1 # 如果是 docker 跑的 redis按实际 host / 端口改
port: 6379
database: 0
password: 123456 # 如果有密码就填上,没密码可以去掉这一行
# ================== SpringDoc ==================
springdoc:
api-docs:
enabled: true
path: /v3/api-docs
swagger-ui:
enabled: true
path: /swagger-ui.html
group-configs:
- group: 'default'
display-name: '工单服务 API'
paths-to-match: '/**'
# ================== Dubbo + Nacos ==================
# ================== Dubbo ==================
dubbo:
application:
name: urban-lifeline-workcase
qos-enable: false
protocol:
name: dubbo
port: -1
registry:
address: nacos://127.0.0.1:8848
payload: 110100480
scan:
base-packages: org.xyzh.workcase.service.impl
# ================== MyBatis ==================
mybatis-plus:
mapper-locations: classpath:mapper/**/*.xml
type-aliases-package: org.xyzh.common.dto, org.xyzh.api
# ================== Logging ==================
logging:
config: classpath:log4j2.xml
charset:
console: UTF-8
file: UTF-8
level:
org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping: TRACE
# ================== Jitsi Meet 视频会议配置 ==================
jitsi:
app:
id: ${JITSI_APP_ID:urbanLifeline}
secret: ${JITSI_APP_SECRET:urbanLifeline-jitsi-secret-key-2025-production-safe-hs256}
server:
url: ${JITSI_SERVER_URL:https://org.xyzh.yslg.jitsi}
token:
expiration: 7200000