# 本配置文件中的相对路径都是相对于部署路径，
# 如 /usr/local/easyops/ucpro_service

service:
  ip: "0.0.0.0"   # 监听ip
  port: 8077      # 监听port, 逻辑组件监听端口应该在8001~8099之间，新组件需要找平台组同学分配端口号。
  mode: release     # "debug" "release" "test"

edition: "cmdb-community"

log:
  level: debug
  logfile:
    filename: "log/ucpro_service.log"
    maxsize: 50     # MB
    maxage: 30      # days
    maxbackups: 20

accesslog:
  filename: "log/ucpro_service_access.log"
  maxsize: 50     # MB
  maxage: 30      # days
  maxbackups: 20

# 分布式追踪配置
tracing:
  enable: false                    # 是否启用分布式追踪
  service_name: "logic.ucpro_service"     # 自身的服务名称
  report_log:
    log_file: "/usr/local/easyops/ens_client/log/trace_log/ucpro_service.log"  # 分布式追踪信息的存储目录
    log_size: 50                 #最大日志文件长度，单位M
    log_count: 2                #最大日志文件数量

path:
  remote_uc_dir: "/data/easyops/tmp/uc"
  conf_dir: "conf/"
  scripts_dir: "scripts/"
  tools_dir: "tools/"
  static_dir: "static/"
  data_dir: "data/"
  time_max_diff: 5 # 最大时间偏差量（秒)
  license_file: "conf/license.lic"
  install_info_file: "conf/install_info.yaml"
  org_range:  # 离线生成org的范围
    min_org: 10000
    max_org: 10000000
  resource_limit:
    cmdb-community:
      mem_limit: 4 # 内存限制, 单位G
      disk_limit: 20 # 磁盘限制，单位G
    enterprise:
      mem_limit: 14 # 内存限制, 单位G
      disk_limit: 50 # 磁盘限制，单位G

download:
  download_dir: "download/"
  download_max_threads: 5 # 组件下载并发数
  download_url_prefix: "http://cdn.uwintech.cn" # 组件下载地址
  components_layout_uri_prefix: "data/release_package/easyops-components-layout"

creator:
  offline_pkg_path: "/tmp/uc_upload_pkg"
  offline_tmp: "/tmp/uc_upload_pkg_tmp/"
  parallelism: 5  # 并发部署任务数
  check_online_timeout: 5 # 自动检查在线模式超时时间(秒)
  check_addr: "www.baidu.com:80"

file_storage:
  data_path: "data/"

enable_features:
  version_dependencies: true  # 版本依赖检查
