summaryrefslogtreecommitdiff
path: root/libpod/kube.go
diff options
context:
space:
mode:
Diffstat (limited to 'libpod/kube.go')
-rw-r--r--libpod/kube.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/libpod/kube.go b/libpod/kube.go
index 22fbb5f9f..eb62643fe 100644
--- a/libpod/kube.go
+++ b/libpod/kube.go
@@ -213,7 +213,7 @@ type YAMLContainer struct {
func ConvertV1PodToYAMLPod(pod *v1.Pod) *YAMLPod {
cs := []*YAMLContainer{}
for _, cc := range pod.Spec.Containers {
- var res *v1.ResourceRequirements = nil
+ var res *v1.ResourceRequirements
if len(cc.Resources.Limits) > 0 || len(cc.Resources.Requests) > 0 {
res = &cc.Resources
}
@@ -525,9 +525,9 @@ func simplePodWithV1Containers(ctx context.Context, ctrs []*Container) (*v1.Pod,
}
podName := strings.ReplaceAll(ctrs[0].Name(), "_", "")
// Check if the pod name and container name will end up conflicting
- // Append _pod if so
+ // Append -pod if so
if util.StringInSlice(podName, ctrNames) {
- podName = podName + "_pod"
+ podName = podName + "-pod"
}
return newPodObject(