aboutsummaryrefslogtreecommitdiff
path: root/weed/util
diff options
context:
space:
mode:
Diffstat (limited to 'weed/util')
-rw-r--r--weed/util/version/constants.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/weed/util/version/constants.go b/weed/util/version/constants.go
index 33b226202..8cbe2225a 100644
--- a/weed/util/version/constants.go
+++ b/weed/util/version/constants.go
@@ -3,6 +3,7 @@ package version
import (
"fmt"
+ "github.com/seaweedfs/seaweedfs/weed/stats"
"github.com/seaweedfs/seaweedfs/weed/util"
)
@@ -14,6 +15,11 @@ var (
COMMIT = ""
)
+func init() {
+ // Set version info in stats for Prometheus metrics
+ stats.SetVersionInfo(VERSION_NUMBER, COMMIT, util.SizeLimit)
+}
+
func Version() string {
return VERSION + " " + COMMIT
}