Stackdriver / stackdriver-prometheus-sidecar

A sidecar for the Prometheus server that can send metrics to Stackdriver.
https://cloud.google.com/monitoring/kubernetes-engine/prometheus
Apache License 2.0
120 stars 43 forks source link

cannot find module providing package #280

Open switchtrue opened 3 years ago

switchtrue commented 3 years ago

I'm trying to do a local install using the recommendation from the readme of go get github.com/Stackdriver/stackdriver-prometheus-sidecar/.... However, when doing this I am getting a few modules that can't be found:

Full output:

github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    go.opencensus.io/exporter/prometheus: cannot find module providing package go.opencensus.io/exporter/prometheus
github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    github.com/prometheus/prometheus/config imports
    github.com/prometheus/prometheus/discovery/config imports
    github.com/prometheus/prometheus/discovery/azure imports
    github.com/Azure/azure-sdk-for-go/arm/compute: cannot find module providing package github.com/Azure/azure-sdk-for-go/arm/compute
github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    github.com/prometheus/prometheus/config imports
    github.com/prometheus/prometheus/discovery/config imports
    github.com/prometheus/prometheus/discovery/azure imports
    github.com/Azure/azure-sdk-for-go/arm/network: cannot find module providing package github.com/Azure/azure-sdk-for-go/arm/network
[mleonard@dcprometheus ~]$ GO111MODULE=on CGO_ENABLED=0 go get github.com/Stackdriver/stackdriver-prometheus-sidecar/...@latest
github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    go.opencensus.io/exporter/prometheus: cannot find module providing package go.opencensus.io/exporter/prometheus
github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    github.com/prometheus/prometheus/config imports
    github.com/prometheus/prometheus/discovery/config imports
    github.com/prometheus/prometheus/discovery/azure imports
    github.com/Azure/azure-sdk-for-go/arm/compute: cannot find module providing package github.com/Azure/azure-sdk-for-go/arm/compute
github.com/Stackdriver/stackdriver-prometheus-sidecar/cmd/stackdriver-prometheus-sidecar imports
    github.com/prometheus/prometheus/config imports
    github.com/prometheus/prometheus/discovery/config imports
    github.com/prometheus/prometheus/discovery/azure imports
    github.com/Azure/azure-sdk-for-go/arm/network: cannot find module providing package github.com/Azure/azure-sdk-for-go/arm/network

go version:

$ go version
go version go1.16.3 linux/amd64

Any ideas on how to resolve this and do a successful local install?