appsettings.json 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. {
  2. "$schema": "https://gitee.com/dotnetchina/Furion/raw/net6/schemas/v3/furion-schema.json",
  3. "Urls": "https://*:5005",
  4. "Logging": {
  5. "LogLevel": {
  6. "Default": "Information",
  7. "Microsoft.AspNetCore": "Warning"
  8. },
  9. "File": {
  10. "Enabled": true, // 启用文件日志
  11. "FileName": "logs/{0:yyyyMMdd}_{1}.log", // 日志文件
  12. "Append": true, // 追加覆盖
  13. // "MinimumLevel": "Information", // 日志级别
  14. "FileSizeLimitBytes": 10485760, // 10M=10*1024*1024
  15. "MaxRollingFiles": 30 // 只保留30个文件
  16. },
  17. "Database": {
  18. "Enabled": true, // 启用数据库日志
  19. "MinimumLevel": "Information"
  20. },
  21. "ElasticSearch": {
  22. "Enabled": false, // 启用ES日志
  23. "ServerUris": [ "http://dilon:123456@192.168.1.100:9200" ], // 地址
  24. "DefaultIndex": "adminnet" // 索引
  25. },
  26. "Monitor": {
  27. "GlobalEnabled": true, // 启用全局拦截日志
  28. "IncludeOfMethods": [], // 拦截特定方法,当GlobalEnabled=false有效
  29. "ExcludeOfMethods": [], // 排除特定方法,当GlobalEnabled=true有效
  30. "BahLogLevel": "Information", // Oops.Oh 和 Oops.Bah 业务日志输出级别
  31. "WithReturnValue": true, // 配置是否包含返回值,默认true
  32. "ReturnValueThreshold": 500, // 配置返回值字符串阈值,默认0全量输出
  33. "JsonBehavior": "None" // 配置Json输出行为,默认None(OnlyJson、All)
  34. }
  35. },
  36. "AllowedHosts": "*"
  37. }