JustBeforeEach(func() { var err error container, err = client.Create(containerSpec) Expect(err).NotTo(HaveOccurred()) hostNetInPort, _, err = container.NetIn(hostNetInPort, 8080) Expect(err).NotTo(HaveOccurred()) container.NetOut(garden.NetOutRule{ Networks: []garden.IPRange{ garden.IPRangeFromIP(net.ParseIP("8.8.8.8")), }, }) info, err := container.Info() Expect(err).NotTo(HaveOccurred()) externalIP = info.ExternalIP interfacePrefix = info.Properties["kawasaki.iptable-prefix"] out := gbytes.NewBuffer() existingProc, err = container.Run( garden.ProcessSpec{ Path: "/bin/sh", Args: []string{"-c", "while true; do echo hello; sleep 1; done;"}, }, garden.ProcessIO{ Stdout: io.MultiWriter(GinkgoWriter, out), Stderr: io.MultiWriter(GinkgoWriter, out), }) Expect(err).NotTo(HaveOccurred())