Skip to content

Commit

Permalink
update tlsCredentials in status commands
Browse files Browse the repository at this point in the history
  • Loading branch information
lynnemorrison committed Dec 12, 2024
1 parent 04ba008 commit 436cf95
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions internal/cmd/skupper/connector/nonkube/connector_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,8 @@ func (cmd *CmdConnectorStatus) Run() error {
status = "Ok"
}
tw := tabwriter.NewWriter(os.Stdout, 8, 8, 1, '\t', tabwriter.TabIndent)
fmt.Fprintln(tw, fmt.Sprintf("Name:\t%s\nStatus:\t%s\nRouting key:\t%s\nHost:\t%s\nPort:\t%d\n",
connector.Name, status, connector.Spec.RoutingKey, connector.Spec.Host, connector.Spec.Port))
fmt.Fprintln(tw, fmt.Sprintf("Name:\t%s\nStatus:\t%s\nRouting key:\t%s\nHost:\t%s\nPort:\t%d\nTlsCredentials:\t%s",
connector.Name, status, connector.Spec.RoutingKey, connector.Spec.Host, connector.Spec.Port, connector.Spec.TlsCredentials))
_ = tw.Flush()
}
}
Expand Down
6 changes: 3 additions & 3 deletions internal/cmd/skupper/listener/nonkube/listener_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,15 @@ func (cmd *CmdListenerStatus) Run() error {
}
} else {
tw := tabwriter.NewWriter(os.Stdout, 8, 8, 1, '\t', tabwriter.TabIndent)
_, _ = fmt.Fprintln(tw, fmt.Sprintf("%s\t%s\t%s\t%s\t%s\t%s",
"NAME", "STATUS", "ROUTING-KEY", "HOST", "PORT", "TLS-CREDENTIALS"))
_, _ = fmt.Fprintln(tw, fmt.Sprintf("%s\t%s\t%s\t%s\t%s",
"NAME", "STATUS", "ROUTING-KEY", "HOST", "PORT"))
for _, listener := range listeners {
status := "Not Ready"
if listener.IsConfigured() {
status = "Ok"
}
fmt.Fprintln(tw, fmt.Sprintf("%s\t%s\t%s\t%s\t%d\t%s",
listener.Name, status, listener.Spec.RoutingKey, listener.Spec.Host, listener.Spec.Port, listener.Spec.TlsCredentials))
listener.Name, status, listener.Spec.RoutingKey, listener.Spec.Host, listener.Spec.Port))
}
_ = tw.Flush()
}
Expand Down
4 changes: 2 additions & 2 deletions internal/nonkube/client/fs/connector_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func (s *ConnectorHandler) Get(name string, opt GetOptions) (*v2alpha1.Connector
err, file := s.ReadFile(s.pathProvider.GetRuntimeNamespace(), fileName, common.Connectors)
if err != nil {
if opt.LogWarning {
os.Stderr.WriteString("Site not initialized yet")
os.Stderr.WriteString("Site not initialized yet\n")
}
err, file = s.ReadFile(s.pathProvider.GetNamespace(), fileName, common.Connectors)
if err != nil {
Expand Down Expand Up @@ -92,7 +92,7 @@ func (s *ConnectorHandler) List() ([]*v2alpha1.Connector, error) {
path := s.pathProvider.GetRuntimeNamespace()
err, files := s.ReadDir(path, common.Connectors)
if err != nil {
os.Stderr.WriteString("Site not initialized yet")
os.Stderr.WriteString("Site not initialized yet\n")
path = s.pathProvider.GetNamespace()
err, files = s.ReadDir(path, common.Connectors)
if err != nil {
Expand Down
4 changes: 2 additions & 2 deletions internal/nonkube/client/fs/listener_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func (s *ListenerHandler) Get(name string, opts GetOptions) (*v2alpha1.Listener,
err, file := s.ReadFile(s.pathProvider.GetRuntimeNamespace(), fileName, common.Listeners)
if err != nil {
if opts.LogWarning {
os.Stderr.WriteString("Site not initialized yet")
os.Stderr.WriteString("Site not initialized yet\n")
}
err, file = s.ReadFile(s.pathProvider.GetNamespace(), fileName, common.Listeners)
if err != nil {
Expand Down Expand Up @@ -93,7 +93,7 @@ func (s *ListenerHandler) List() ([]*v2alpha1.Listener, error) {
path := s.pathProvider.GetRuntimeNamespace()
err, files := s.ReadDir(path, common.Listeners)
if err != nil {
os.Stderr.WriteString("Site not initialized yet")
os.Stderr.WriteString("Site not initialized yet\n")
path = s.pathProvider.GetNamespace()
err, files = s.ReadDir(path, common.Listeners)
if err != nil {
Expand Down

0 comments on commit 436cf95

Please sign in to comment.