diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-02-16 05:56:26 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-16 05:56:26 -0500 |
commit | ac9a048b59ebcbdfd2cb7abb50a97981892bd6b6 (patch) | |
tree | bff7197bd3fd501d49c9baa3ec605b0f7b06caae /pkg/systemd/generate/containers.go | |
parent | df8ba7f4a92750bfb173b5486a663d1735d70b2d (diff) | |
parent | bf083c185d766fb9eb79c08b2d831da0fa2abafd (diff) | |
download | podman-ac9a048b59ebcbdfd2cb7abb50a97981892bd6b6.tar.gz podman-ac9a048b59ebcbdfd2cb7abb50a97981892bd6b6.tar.bz2 podman-ac9a048b59ebcbdfd2cb7abb50a97981892bd6b6.zip |
Merge pull request #9375 from Luap99/fix-9373
Fix broken podman generate systemd --new with pods
Diffstat (limited to 'pkg/systemd/generate/containers.go')
-rw-r--r-- | pkg/systemd/generate/containers.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/systemd/generate/containers.go b/pkg/systemd/generate/containers.go index abe159812..acee7be65 100644 --- a/pkg/systemd/generate/containers.go +++ b/pkg/systemd/generate/containers.go @@ -68,7 +68,7 @@ type containerInfo struct { // If not nil, the container is part of the pod. We can use the // podInfo to extract the relevant data. - pod *podInfo + Pod *podInfo } const containerTemplate = headerTemplate + ` @@ -215,8 +215,8 @@ func executeContainerTemplate(info *containerInfo, options entities.GenerateSyst ) // If the container is in a pod, make sure that the // --pod-id-file is set correctly. - if info.pod != nil { - podFlags := []string{"--pod-id-file", info.pod.PodIDFile} + if info.Pod != nil { + podFlags := []string{"--pod-id-file", "{{{{.Pod.PodIDFile}}}}"} startCommand = append(startCommand, podFlags...) info.CreateCommand = filterPodFlags(info.CreateCommand) } |