Skip to content

Commit

Permalink
improve log message for network-> endpoint again
Browse files Browse the repository at this point in the history
  • Loading branch information
sduchesneau committed Sep 27, 2023
1 parent 6a50682 commit 6ea647e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions manifest/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@ package manifest

import (
"fmt"
"go.uber.org/zap"
"os"
"strings"

"go.uber.org/zap"

"gopkg.in/yaml.v3"
)

Expand Down Expand Up @@ -42,12 +43,12 @@ func ExtractNetworkEndpoint(networkFromManifest, fromFlag string, logger *zap.Lo
}

if endpoint := getNetworkEndpointFromEnvironment(networkFromManifest); endpoint != "" {
logger.Info("using endpoint from environment", zap.String("endpoint", endpoint))
logger.Info("using endpoint from environment", zap.String("manifest_network", networkFromManifest), zap.String("endpoint", endpoint))
return endpoint, nil
}

if ep, ok := HardcodedEndpoints[networkFromManifest]; ok {
logger.Info("using endpoint from hardcoded list", zap.String("endpoint", ep))
logger.Info("using endpoint from hardcoded list", zap.String("manifest_network", networkFromManifest), zap.String("endpoint", ep))
return ep, nil
}

Expand Down

0 comments on commit 6ea647e

Please sign in to comment.