@@ -4,7 +4,6 @@ package integration
44
55import (
66 "fmt"
7- "io"
87 "os"
98 "path/filepath"
109 "runtime"
@@ -668,33 +667,13 @@ var _ = Describe("Podman pull", func() {
668667
669668 podmanTest .AddImageToRWStore (ALPINE )
670669
671- success := false
672- registryArgs := []string {"run" , "-d" , "--name" , "registry" , "-p" , "5012:5000" }
673670 if isRootless () {
674671 err := podmanTest .RestoreArtifact (REGISTRY_IMAGE )
675672 Expect (err ).ToNot (HaveOccurred ())
676-
677- // Debug code for https://github.com/containers/podman/issues/24219
678- logFile := filepath .Join (podmanTest .TempDir , "pasta.log" )
679- registryArgs = append (registryArgs , "--network" , "pasta:--trace,--log-file," + logFile )
680- defer func () {
681- if success {
682- // only print the log on errors otherwise it will clutter CI logs way to much
683- return
684- }
685-
686- f , err := os .Open (logFile )
687- Expect (err ).ToNot (HaveOccurred ())
688- defer f .Close ()
689- GinkgoWriter .Println ("pasta trace log:" )
690- _ , err = io .Copy (GinkgoWriter , f )
691- Expect (err ).ToNot (HaveOccurred ())
692- }()
693673 }
694- registryArgs = append (registryArgs , REGISTRY_IMAGE , "/entrypoint.sh" , "/etc/docker/registry/config.yml" )
695674 lock := GetPortLock ("5012" )
696675 defer lock .Unlock ()
697- session := podmanTest .Podman (registryArgs )
676+ session := podmanTest .Podman ([] string { "run" , "-d" , "--name" , "registry" , "-p" , "5012:5000" , REGISTRY_IMAGE , "/entrypoint.sh" , "/etc/docker/registry/config.yml" } )
698677 session .WaitWithDefaultTimeout ()
699678 Expect (session ).Should (ExitCleanly ())
700679
@@ -707,8 +686,6 @@ var _ = Describe("Podman pull", func() {
707686 session = decryptionTestHelper (imgPath )
708687
709688 Expect (session .LineInOutputContainsTag (imgPath , "latest" )).To (BeTrue ())
710-
711- success = true
712689 })
713690 })
714691
0 commit comments