code.gitea.io/gitea@v1.19.3/modules/setting/metrics.go (about)

     1  // Copyright 2023 The Gitea Authors. All rights reserved.
     2  // SPDX-License-Identifier: MIT
     3  
     4  package setting
     5  
     6  // Metrics settings
     7  var Metrics = struct {
     8  	Enabled                  bool
     9  	Token                    string
    10  	EnabledIssueByLabel      bool
    11  	EnabledIssueByRepository bool
    12  }{
    13  	Enabled:                  false,
    14  	Token:                    "",
    15  	EnabledIssueByLabel:      false,
    16  	EnabledIssueByRepository: false,
    17  }
    18  
    19  func loadMetricsFrom(rootCfg ConfigProvider) {
    20  	mustMapSetting(rootCfg, "metrics", &Metrics)
    21  }