diff --git a/lib/ui/dashboard.js b/lib/ui/dashboard.js index 9dc5285..bff3a19 100644 --- a/lib/ui/dashboard.js +++ b/lib/ui/dashboard.js @@ -161,8 +161,9 @@ class Dashboard { if (!k8s.isPodRunning(pod)) return; const name = pod.metadata.name; const namespace = pod.metadata.namespace; - // FIXME: select which container in pod - const container = pod.spec.containers[0].name; + const container = pod.metadata.uid === pod_selected && container_selected + ? container_selected + : pod.spec.containers[0].name; const id = `${namespace}-${name}-${container}`; const byId = page => page.id === id; // check if connection already exists