Skip to content

Commit

Permalink
Merge branch 'main' of ../private
Browse files Browse the repository at this point in the history
  • Loading branch information
lunar-devops committed Feb 28, 2024
2 parents 3b772ce + d609307 commit 70cc720
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion proxy/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ ENV LUNAR_TELEMETRY_LOG_LEVEL info
ENV AWS_ACCESS_KEY_ID ${AWS_ACCESS_KEY_ID}
ENV AWS_SECRET_ACCESS_KEY ${AWS_SECRET_ACCESS_KEY}
ENV LUNAR_FLUSH_SECONDS 5
ENV LUNAR_HUB_URL ""
ENV LUNAR_HUB_URL "hub.lunar.dev"
ENV LUNAR_API_KEY ""
ENV LUNAR_EXPORTER_S3_KEY_FORMAT "/"
ENV LUNAR_EXPORTER_S3_MINIO_KEY_FORMAT "/"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ const (
lunarHubReportIntervalEnvVar string = "HUB_REPORT_INTERVAL"
discoveryStateLocationEnvVar string = "DISCOVERY_STATE_LOCATION"
remedyStatsStateLocationEnvVar string = "REMEDY_STATE_LOCATION"

lunarHubDefaultValue string = "hub.lunar.dev"
)

func GetTenantName() string {
Expand Down Expand Up @@ -91,7 +93,12 @@ func GetRedisMaxOLRetryAttempts() (int, error) {
}

func GetHubURL() string {
return os.Getenv(lunarHubURLEnvVar)
lunarHubURL := os.Getenv(lunarHubURLEnvVar)
if lunarHubURL == "" {
log.Warn().Msgf("Could not find Lunar Hub URL from ENV, using default: %s", lunarHubDefaultValue)
lunarHubURL = lunarHubDefaultValue
}
return lunarHubURL
}

func GetAPIKey() string {
Expand Down

0 comments on commit 70cc720

Please sign in to comment.