mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-01 18:58:18 +00:00
Add init container loading to the kubelet
This commit is contained in:
@@ -465,6 +465,13 @@ func (s *Server) getContainerLogs(request *restful.Request, response *restful.Re
|
||||
containerExists = true
|
||||
}
|
||||
}
|
||||
if !containerExists {
|
||||
for _, container := range pod.Spec.InitContainers {
|
||||
if container.Name == containerName {
|
||||
containerExists = true
|
||||
}
|
||||
}
|
||||
}
|
||||
if !containerExists {
|
||||
response.WriteError(http.StatusNotFound, fmt.Errorf("container %q not found in pod %q\n", containerName, podID))
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user