env.go 682 B

123456789101112131415
  1. package inferencecost
  2. import (
  3. "time"
  4. coreenv "github.com/opencost/opencost/core/pkg/env"
  5. "github.com/opencost/opencost/pkg/env"
  6. )
  7. func isInferenceCostEnabled() bool { return env.IsInferenceCostEnabled() }
  8. func getPrometheusURL() string { return coreenv.Get("PROMETHEUS_SERVER_ENDPOINT", "") }
  9. func getModelLabel() string { return env.GetInferenceModelLabel() }
  10. func getSharedInfraLabel() string { return env.GetInferenceSharedInfraLabel() }
  11. func getSharedInfraLabelValue() string { return env.GetInferenceSharedInfraLabelValue() }
  12. func getCollectionInterval() time.Duration { return env.GetInferenceCollectionInterval() }