ofesseler / gluster_exporter

Gluster Exporter for Prometheus
Apache License 2.0
81 stars 57 forks source link

Installation failed "go get no longer supported" #51

Open mozai opened 2 years ago

mozai commented 2 years ago

using go version go1.18.1 linux/amd64

Installation instruction in readme.md says go get github.com/ofesseler/gluster_exporter

What I saw:

go: go.mod file not found in current directory or any parent directory. 'go get' is no longer supported outside a module. To build and install a command, use 'go install' with a version, like 'go install example.com/cmd@latest' For more information, see https://golang.org/doc/go-get-install-deprecation or run 'go help get' or 'go help install'.

So I tried go install github.com/ofesseler/gluster_exporter@latest

What I saw:

go: finding module for package github.com/prometheus/common/version go: finding module for package github.com/prometheus/client_golang/prometheus/promhttp go: finding module for package github.com/prometheus/common/log go: finding module for package github.com/prometheus/client_golang/prometheus go: found github.com/prometheus/client_golang/prometheus in github.com/prometheus/client_golang v1.12.1 go: found github.com/prometheus/client_golang/prometheus/promhttp in github.com/prometheus/client_golang v1.12.1 go: found github.com/prometheus/common/version in github.com/prometheus/common v0.34.0 go: finding module for package github.com/prometheus/common/log [redacted]/go/pkg/mod/github.com/ofesseler/gluster_exporter@v0.2.7/structs/xmlStructs.go:8:2: module github.com/prometheus/common@latest found (v0.34.0), but does not contain package github.com/prometheus/common/log