Skip to content

Commit

Permalink
Merge pull request #2571 from openshift-cherrypick-robot/cherry-pick-…
Browse files Browse the repository at this point in the history
…2566-to-release_1.2.47

[release_1.2.47] OCM-12101 | fix: Adding log outputs for empty values
  • Loading branch information
davidleerh authored Oct 25, 2024
2 parents 23da3b1 + f886af8 commit 17e5745
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cmd/create/network/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,15 +87,18 @@ func NetworkRunner(userOptions *opts.NetworkUserOptions) rosa.CommandRunner {
}

if parsedParams["Name"] == "" {
r.Logger.Debugf("Name not provided, using default name %s", r.Creator.AccountID)
r.Reporter.Infof("Name not provided, using default name %s", r.Creator.AccountID)
parsedParams["Name"] = "rosa-network-stack-" + r.Creator.AccountID
}
if parsedParams["Region"] == "" {
r.Logger.Debugf("Region not provided, using default region %s", r.AWSClient.GetRegion())
r.Reporter.Infof("Region not provided, using default region %s", r.AWSClient.GetRegion())
parsedParams["Region"] = r.AWSClient.GetRegion()
}

// Extract the first non-`--param` argument to use as the template command
if len(argv) == 0 {
r.Reporter.Infof("Template command not provided, using default template %s", templateCommand)
}
for _, arg := range argv {
if !strings.HasPrefix(arg, "--param") {
templateCommand = arg
Expand Down

0 comments on commit 17e5745

Please sign in to comment.