Skip to content
This repository was archived by the owner on Oct 14, 2020. It is now read-only.

Commit cc60ba4

Browse files
committed
Use actual namespace in lurcher
1 parent 2bd05f4 commit cc60ba4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lurcher/main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ func waitForMainContainerToEnd(container, pod, namespace string) {
9898
log.Printf("Waiting for maincontainer to exit.")
9999

100100
for {
101-
pod, err := clientset.CoreV1().Pods("default").Get(pod, metav1.GetOptions{})
101+
pod, err := clientset.CoreV1().Pods(namespace).Get(pod, metav1.GetOptions{})
102102
if kerrors.IsNotFound(err) {
103-
log.Printf("Pod %s not found in default namespace", pod)
103+
log.Printf("Pod %s not found in namespace %s", pod, namespace)
104104
} else if statusError, isStatus := err.(*kerrors.StatusError); isStatus {
105105
log.Printf("Error getting pod %v", statusError.ErrStatus.Message)
106106
} else if err != nil {

0 commit comments

Comments
 (0)