summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-01-11 00:25:09 +0100
committerGitHub <noreply@github.com>2022-01-11 00:25:09 +0100
commited9ef59e7ea439b670875863132b68fd094501c7 (patch)
tree02ef3d057b928b7903954a54dc7ba0f7ab466763 /pkg
parent2790b5c69c729df7ba83b214800de387fd43c646 (diff)
parent19a475906612b603b11fbbf6ee6a6978a4bd9586 (diff)
downloadpodman-ed9ef59e7ea439b670875863132b68fd094501c7.tar.gz
podman-ed9ef59e7ea439b670875863132b68fd094501c7.tar.bz2
podman-ed9ef59e7ea439b670875863132b68fd094501c7.zip
Merge pull request #12780 from rhatdan/pod
Use the InfraImage defined in containers.conf
Diffstat (limited to 'pkg')
-rw-r--r--pkg/api/handlers/libpod/pods.go12
1 files changed, 2 insertions, 10 deletions
diff --git a/pkg/api/handlers/libpod/pods.go b/pkg/api/handlers/libpod/pods.go
index 1b29831b4..43b39060b 100644
--- a/pkg/api/handlers/libpod/pods.go
+++ b/pkg/api/handlers/libpod/pods.go
@@ -7,7 +7,6 @@ import (
"strings"
"time"
- "github.com/containers/common/pkg/config"
"github.com/containers/podman/v3/libpod"
"github.com/containers/podman/v3/libpod/define"
"github.com/containers/podman/v3/pkg/api/handlers"
@@ -62,15 +61,8 @@ func PodCreate(w http.ResponseWriter, r *http.Request) {
psg.InfraContainerSpec.Name = psg.InfraName
psg.InfraContainerSpec.ConmonPidFile = psg.InfraConmonPidFile
psg.InfraContainerSpec.ContainerCreateCommand = psg.InfraCommand
- imageName := psg.InfraImage
- rawImageName := psg.InfraImage
- if imageName == "" {
- imageName = config.DefaultInfraImage
- rawImageName = config.DefaultInfraImage
- }
- psg.InfraImage = imageName
- psg.InfraContainerSpec.Image = imageName
- psg.InfraContainerSpec.RawImageName = rawImageName
+ psg.InfraContainerSpec.Image = psg.InfraImage
+ psg.InfraContainerSpec.RawImageName = psg.InfraImage
}
podSpecComplete := entities.PodSpec{PodSpecGen: psg}
pod, err := generate.MakePod(&podSpecComplete, runtime)