aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/main.go b/main.go
index 444e5b0..89a8608 100644
--- a/main.go
+++ b/main.go
@@ -11,6 +11,7 @@ import (
"syscall"
"time"
+ "github.com/prometheus/client_golang/prometheus/promhttp"
"go.lindenii.runxiyu.org/lindenii-common/clog"
)
@@ -103,5 +104,9 @@ func main() {
// IRC bot
go ircBotLoop()
+ // Prometheus
+ http.Handle("/metrics", promhttp.Handler())
+ go http.ListenAndServe(":9112", nil)
+
select {}
}