mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-06 10:43:56 +00:00
Escape manifest IDs when hunting the network container.
This makes it possible to have manifests with _ in the ID. I'm not sure we want to allow this, but we do for now. I hope to follow this up with a deeper change to make this a bit more robust.
This commit is contained in:
parent
e811e24b23
commit
8c2a8b65c3
@ -620,7 +620,7 @@ func (kl *Kubelet) networkContainerExists(manifest *api.ContainerManifest) (stri
|
||||
return "", false, err
|
||||
}
|
||||
for _, name := range pods {
|
||||
if strings.Contains(name, containerNamePrefix+"--"+networkContainerName+"--"+manifest.Id+"--") {
|
||||
if strings.Contains(name, containerNamePrefix+"--"+networkContainerName+"--"+escapeDash(manifest.Id)+"--") {
|
||||
return name, true, nil
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user