diff options
Diffstat (limited to 'cmd/podman/play/kube.go')
-rw-r--r-- | cmd/podman/play/kube.go | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/cmd/podman/play/kube.go b/cmd/podman/play/kube.go index d2cfe8d43..17f3b430d 100644 --- a/cmd/podman/play/kube.go +++ b/cmd/podman/play/kube.go @@ -92,8 +92,10 @@ func kube(cmd *cobra.Command, args []string) error { return err } - for _, l := range report.Logs { - fmt.Fprintf(os.Stderr, l) + for _, pod := range report.Pods { + for _, l := range pod.Logs { + fmt.Fprintf(os.Stderr, l) + } } switch len(report.Pods) { @@ -105,19 +107,19 @@ func kube(cmd *cobra.Command, args []string) error { fmt.Printf("Pods:\n") } for _, pod := range report.Pods { - fmt.Println(pod) - } - - switch len(report.Containers) { - case 0: - return nil - case 1: - fmt.Printf("Container:\n") - default: - fmt.Printf("Containers:\n") - } - for _, ctr := range report.Containers { - fmt.Println(ctr) + fmt.Println(pod.ID) + + switch len(pod.Containers) { + case 0: + return nil + case 1: + fmt.Printf("Container:\n") + default: + fmt.Printf("Containers:\n") + } + for _, ctr := range pod.Containers { + fmt.Println(ctr) + } } return nil |