Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating SkupperPodmanSite.Status to check if site.AuthMode is internal. #1453

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion cmd/skupper/skupper_podman_site.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,9 @@ func (s *SkupperPodmanSite) Status(cmd *cobra.Command, args []string) error {

if site.EnableFlowCollector {
statusOutput.ConsoleUrl = site.GetConsoleUrl()
statusOutput.Credentials = formatter.PlatformSupport{"podman volume", "'skupper-console-users'"}
if site.AuthMode == "internal" {
statusOutput.Credentials = formatter.PlatformSupport{"podman volume", "'skupper-console-users'"}
}
}

if verboseStatus {
Expand Down
5 changes: 2 additions & 3 deletions pkg/utils/formatter/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,12 @@ func PrintStatus(data StatusData) error {
fmt.Println()

if len(data.ConsoleUrl) > 0 {
fmt.Println("The site console url is: ", data.ConsoleUrl)
fmt.Printf("The site console url is: %s\n", data.ConsoleUrl)
if len(data.Credentials.SupportName) > 0 {
fmt.Printf("The credentials for internal console-auth mode are held in %s: %s", data.Credentials.SupportType, data.Credentials.SupportName)
fmt.Printf("The credentials for internal console-auth mode are held in %s: %s\n", data.Credentials.SupportType, data.Credentials.SupportName)
}
}

fmt.Println()
return nil
}

Expand Down