xyc
4 小时以前 5b41c8896ef7850be2672e45b69bb58e149729ec
traffic-audit-server/src/main/resources/application.yml.example
@@ -1,12 +1,22 @@
# 复制为 application.yml 并替换占位符后使用(真实密钥不入库)
server:
  port: 8090
  tomcat:
    basedir: .
    threads:
      max: 500
    accesslog:
      enabled: true
      directory: logs
      prefix: access
      suffix: .log
      pattern: '%h %l %u %t "%r" %s %b %D'
spring:
  datasource:
    url: jdbc:mysql://localhost:3305/traffic_audit?useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai&useSSL=false&allowPublicKeyRetrieval=true&rewriteBatchedStatements=true
    username: root
    password: ${MYSQL_PASSWORD:root}
    username: ${TRAFFIC_DB_USER:root}
    password: ${TRAFFIC_DB_PASSWORD}
    driver-class-name: com.mysql.cj.jdbc.Driver
  servlet:
    multipart:
@@ -21,7 +31,8 @@
  type-aliases-package: com.trafficaudit
  configuration:
    map-underscore-to-camel-case: true
    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
    # 显式指定 Slf4j:MyBatis-Plus 默认 StdOutImpl 会把整行数据(含企业名/电话)打进日志
    log-impl: org.apache.ibatis.logging.slf4j.Slf4jImpl
  global-config:
    db-config:
      id-type: auto
@@ -30,7 +41,8 @@
      logic-not-delete-value: 0
jwt:
  secret: ${JWT_SECRET:change-me-jwt-secret}
  # 必须是「Base64 合法字符 + 长度是 4 的倍数」;下面这串 32 位十六进制可直接用
  secret: ${TRAFFIC_JWT_SECRET:8f2c1d64a7b34e09c5d81f6a2b0e7c93}
  expiration: 86400000
docs:
@@ -51,7 +63,38 @@
investment:
  template-dir: docs/投资/模板
ledger:
  audit:
    max-issues: 10000
    map:
      # Map distance is mandatory for turnover over-reporting calculations.
      required: true
      # auto selects AMap first, then Baidu. Explicit values: amap, baidu, osrm, none.
      provider: ${LEDGER_MAP_PROVIDER:auto}
      # OSRM needs a geocoder. Explicit values: amap, baidu or nominatim.
      geocoder: ${LEDGER_MAP_GEOCODER:auto}
      amap-key: ${AMAP_WEB_SERVICE_KEY:}
      baidu-ak: ${BAIDU_MAP_AK:}
      osrm-base-url: ${OSRM_BASE_URL:https://router.project-osrm.org}
      # For production, point this to a self-hosted Nominatim instance.
      nominatim-base-url: ${NOMINATIM_BASE_URL:https://nominatim.openstreetmap.org}
      # Public Nominatim requires at most one request per second; set 0 for a private instance.
      nominatim-min-interval-ms: ${NOMINATIM_MIN_INTERVAL_MS:1100}
      nominatim-user-agent: ${NOMINATIM_USER_AGENT:trafficAudit-ledger-audit/1.0}
      timeout-ms: 5000
      max-route-pairs: 5000
deepseek:
  api-key: ${DEEPSEEK_API_KEY:your-deepseek-api-key}
  api-url: https://api.deepseek.com/v1/chat/completions
  model: deepseek-chat
# Behavior captcha on login. Set to false to skip verification during test phase; enable before production release.
app:
  cors:
    # 允许跨域访问接口的来源(逗号分隔,支持 * 通配主机与端口):
    # 浏览器 POST/PUT/DELETE 必带 Origin(GET 不带),故用 IP/域名打开页面时该来源必须命中此列表,否则 403。
    # 默认放行本机与内网网段;若通过域名访问,请把该域名(含端口)追加到此处。
    allowed-origins: http://localhost:*,http://127.0.0.1:*,http://192.168.*:*,http://10.*:*,http://172.*:*
  captcha:
    required: false