# 配置文件

框架配置文件如下所示

{

  "RoutePrefix": "", //路由前缀值
  "AllowedHosts": "*",
  //数据库连接字符串
  "ConnectionStrings": {
    "Local": "Server=(localdb)\\mssqllocaldb;Database=LessSharpData;Trusted_Connection=True;MultipleActiveResultSets=true",
    "SqlServer": "Data Source=.;Initial Catalog=LessSharpData;User ID=sa;Password=xxxx;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"
  },
  //Redis缓存
  "Redis": {
    "Enable": true,
    "Connection": "127.0.0.1:6379",
    "InstanceName": "LessSharp:",
    "Database": 0
  },
  //Jwt配置
  "Jwt": {
    "Issuer": "http://caijt.com",
    "Audience": "http://caijt.com",
    "AccessExpiresIn": 3600, //访问Token的有效时间,以秒为单位
    "AccessSecretKey": "xxxxx", //访问Token的加密key
    "RefreshExpiresIn": 86400, //刷新Token的有效时间,以秒为单位
    "RememberRefreshExpiresIn": 604800, //当登录时选了记住我后,刷新Token的有效时间,以秒为单位
    "RefreshSecretKey": "xxxxx" //刷新Token的加密key
  },
  //附件上传配置
  "Upload": {
    "PublicUploadPath": "~/Uploads", //公共附件保存的目录,~代表wwwroot目录
    "PublicPathPrefix": "/Uploads", //公共附件的url路径前缀
    "PrivateUploadPath": "../Uploads" //秘密附件保存目录
  },
  //企业微信
  "QyWeixin": {
    "CcorpId": "xxxxx",
    "Secret": "xxxxx"
  },
  //腾讯地图
  "QQMap": {
    "Key": "xxxxx"
  }
}

上次更新: 1/3/2021, 9:01:12 PM