summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.cirrus.yml6
-rw-r--r--Makefile6
-rwxr-xr-xcontrib/cirrus/integration_test.sh8
-rwxr-xr-xcontrib/cirrus/setup_environment.sh1
-rw-r--r--contrib/spec/podman.spec.in13
-rw-r--r--libpod/events/journal_linux.go3
-rw-r--r--libpod/events/journal_unsupported.go3
-rw-r--r--libpod/runtime.go2
-rw-r--r--libpod/runtime_pod_linux.go10
-rw-r--r--test/e2e/info_test.go1
-rw-r--r--test/e2e/libpod_suite_remoteclient_test.go1
11 files changed, 50 insertions, 4 deletions
diff --git a/.cirrus.yml b/.cirrus.yml
index 4f47bd400..d26c1ec11 100644
--- a/.cirrus.yml
+++ b/.cirrus.yml
@@ -73,6 +73,7 @@ env:
#### Default to NOT operating in any special-case testing mode
####
SPECIALMODE: "none" # don't do anything special
+ TEST_REMOTE_CLIENT: false # don't test remote client by default
####
#### Credentials and other secret-sauces, decrypted at runtime when authorized.
@@ -266,6 +267,11 @@ testing_task:
- "vendor"
- "build_each_commit"
+ env:
+ matrix:
+ TEST_REMOTE_CLIENT: true
+ TEST_REMOTE_CLIENT: false
+
gce_instance:
image_project: "libpod-218412"
zone: "us-central1-a" # Required by Cirrus for the time being
diff --git a/Makefile b/Makefile
index cacc651dd..10de8ad4e 100644
--- a/Makefile
+++ b/Makefile
@@ -212,7 +212,9 @@ ginkgo:
ginkgo-remote:
ginkgo -v -tags "$(BUILDTAGS) remoteclient" $(GINKGOTIMEOUT) -cover -flakeAttempts 3 -progress -trace -noColor test/e2e/.
-localintegration: varlink_generate test-binaries ginkgo ginkgo-remote
+localintegration: varlink_generate test-binaries ginkgo
+
+remoteintegration: varlink_generate test-binaries ginkgo-remote
localsystem: .install.ginkgo
ginkgo -v -noColor test/system/
@@ -262,7 +264,9 @@ install: .gopathok install.bin install.man install.cni install.systemd ## Insta
install.bin:
install ${SELINUXOPT} -d -m 755 $(BINDIR)
install ${SELINUXOPT} -m 755 bin/podman $(BINDIR)/podman
+ install ${SELINUXOPT} -m 755 bin/podman-remote $(BINDIR)/podman-remote
test -z "${SELINUXOPT}" || chcon --verbose --reference=$(BINDIR)/podman bin/podman
+ test -z "${SELINUXOPT}" || chcon --verbose --reference=$(BINDIR)/podman bin/podman-remote
install.man: docs
install ${SELINUXOPT} -d -m 755 $(MANDIR)/man1
diff --git a/contrib/cirrus/integration_test.sh b/contrib/cirrus/integration_test.sh
index 5b73f0c6c..c7d381318 100755
--- a/contrib/cirrus/integration_test.sh
+++ b/contrib/cirrus/integration_test.sh
@@ -36,6 +36,7 @@ else
make
make install PREFIX=/usr ETCDIR=/etc
make test-binaries
+ make install.tools
clean_env
case "${OS_RELEASE_ID}-${OS_RELEASE_VER}" in
@@ -49,6 +50,11 @@ else
;;
*) bad_os_id_ver ;;
esac
- make localintegration
+ if [[ "$TEST_REMOTE_CLIENT" == "true" ]]
+ then
+ make remoteintegration
+ else
+ make localintegration
+ fi
exit $?
fi
diff --git a/contrib/cirrus/setup_environment.sh b/contrib/cirrus/setup_environment.sh
index 98276b70c..4dbd56ed9 100755
--- a/contrib/cirrus/setup_environment.sh
+++ b/contrib/cirrus/setup_environment.sh
@@ -36,6 +36,7 @@ then
"export OS_RELEASE_ID=\"$(os_release_id)\"" \
"export OS_RELEASE_VER=\"$(os_release_ver)\"" \
"export OS_REL_VER=\"$(os_release_id)-$(os_release_ver)\"" \
+ "export TEST_REMOTE_CLIENT=\"$TEST_REMOTE_CLIENT\"" \
"export BUILT_IMAGE_SUFFIX=\"-$CIRRUS_REPO_NAME-${CIRRUS_CHANGE_IN_REPO:0:8}\"" \
"export GOPATH=\"/var/tmp/go\"" \
'export PATH="$HOME/bin:$GOPATH/bin:/usr/local/bin:$PATH"' \
diff --git a/contrib/spec/podman.spec.in b/contrib/spec/podman.spec.in
index d69b673e0..29c786ca6 100644
--- a/contrib/spec/podman.spec.in
+++ b/contrib/spec/podman.spec.in
@@ -185,6 +185,14 @@ Provides: bundled(golang(k8s.io/utils)) = 258e2a2fa64568210fbd6267cf1d8fd87c3cb8
%{repo} provides a library for applications looking to use
the Container Pod concept popularized by Kubernetes.
+%package remote
+Summary: Remote Podman client
+
+%description -n podman-remote
+%{summary}
+This package provides the Podman remote client which
+can be used to access Podman running on a server.
+
%if 0%{?with_devel}
%package devel
Summary: Library for applications looking to use Container Pods
@@ -491,6 +499,11 @@ export GOPATH=%{buildroot}/%{gopath}:$(pwd)/vendor:%{gopath}
%doc README.md CONTRIBUTING.md pkg/hooks/README-hooks.md install.md code-of-conduct.md transfer.md
%endif
+%files -n podman-remote
+%license LICENSE
+%doc README.md CONTRIBUTING.md pkg/hooks/README-hooks.md install.md code-of-conduct.md transfer.md
+%{_bindir}/%{name}-remote
+
%changelog
* Sat Aug 4 2018 Dan Walsh <dwalsh@redhat.com> - 0.8.1-1.git6b4ab2a
- Bump to v0.8.1
diff --git a/libpod/events/journal_linux.go b/libpod/events/journal_linux.go
index 264c84f89..78a630e9a 100644
--- a/libpod/events/journal_linux.go
+++ b/libpod/events/journal_linux.go
@@ -12,6 +12,9 @@ import (
"github.com/sirupsen/logrus"
)
+// DefaultEventerType is journald when systemd is available
+const DefaultEventerType = Journald
+
// EventJournalD is the journald implementation of an eventer
type EventJournalD struct {
options EventerOptions
diff --git a/libpod/events/journal_unsupported.go b/libpod/events/journal_unsupported.go
index c91d81f12..004efdab2 100644
--- a/libpod/events/journal_unsupported.go
+++ b/libpod/events/journal_unsupported.go
@@ -2,6 +2,9 @@
package events
+// DefaultEventerType is logfile when systemd is not present
+const DefaultEventerType = LogFile
+
// newEventJournalD always returns an error if libsystemd not found
func newEventJournalD(options EventerOptions) (Eventer, error) {
return nil, ErrNoJournaldLogging
diff --git a/libpod/runtime.go b/libpod/runtime.go
index e6b84014e..18e9dfeb3 100644
--- a/libpod/runtime.go
+++ b/libpod/runtime.go
@@ -304,7 +304,7 @@ func defaultRuntimeConfig() (RuntimeConfig, error) {
EnablePortReservation: true,
EnableLabeling: true,
NumLocks: 2048,
- EventsLogger: "journald",
+ EventsLogger: events.DefaultEventerType.String(),
}, nil
}
diff --git a/libpod/runtime_pod_linux.go b/libpod/runtime_pod_linux.go
index 456ad365f..124d0daf8 100644
--- a/libpod/runtime_pod_linux.go
+++ b/libpod/runtime_pod_linux.go
@@ -308,5 +308,15 @@ func (r *Runtime) removePod(ctx context.Context, p *Pod, removeCtrs, force bool)
// Mark pod invalid
p.valid = false
p.newPodEvent(events.Remove)
+
+ // Deallocate the pod lock
+ if err := p.lock.Free(); err != nil {
+ if removalErr == nil {
+ removalErr = errors.Wrapf(err, "error freeing pod %s lock", p.ID())
+ } else {
+ logrus.Errorf("Error freeing pod %s lock: %v", p.ID(), err)
+ }
+ }
+
return removalErr
}
diff --git a/test/e2e/info_test.go b/test/e2e/info_test.go
index ca4012dde..c960fb311 100644
--- a/test/e2e/info_test.go
+++ b/test/e2e/info_test.go
@@ -24,7 +24,6 @@ var _ = Describe("Podman Info", func() {
}
podmanTest = PodmanTestCreate(tempdir)
podmanTest.Setup()
- podmanTest.DelayForVarlink()
})
AfterEach(func() {
diff --git a/test/e2e/libpod_suite_remoteclient_test.go b/test/e2e/libpod_suite_remoteclient_test.go
index 05c355711..b7fd8537d 100644
--- a/test/e2e/libpod_suite_remoteclient_test.go
+++ b/test/e2e/libpod_suite_remoteclient_test.go
@@ -77,6 +77,7 @@ func (p *PodmanTestIntegration) StartVarlink() {
command.SysProcAttr = &syscall.SysProcAttr{Setpgid: true}
p.VarlinkCommand = command
p.VarlinkSession = command.Process
+ p.DelayForVarlink()
}
func (p *PodmanTestIntegration) StopVarlink() {