Commit Graph

6854 Commits

Author SHA1 Message Date
OpenShift Merge Robot 25d29f959a
Merge pull request #5338 from umohnani8/vendor-buildah
Vendor in latest containers/buildah
2020-02-27 17:51:45 +01:00
Ed Santiago cabd6c1607 CI: package_versions: include hostinfo, kernel
In the package_versions CI step, include Fedora/Ubuntu
version, uname -r, and cgroups version.

Cgroups version is simply the FS type of /sys/fs/cgroup,
which shows 'tmpfs' for v1 and 'cgroup2fs' for v2. I
don't think it's worth the effort to prettify those
into 'v1/v2' - I think our readers are sophisticated
enough to figure it out from context - but am willing
to add that feature if requested.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-02-27 09:40:35 -07:00
Urvashi Mohnani 151bf72bed Vendor in latest containers/buildah
Pulls in fix that sets the correct ownership on
the working directory during the build process.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2020-02-27 09:12:10 -05:00
OpenShift Merge Robot c132a4b7ff
Merge pull request #5295 from mheon/advanced_network_inspect
Add support for multiple CNI networks in podman inspect
2020-02-27 12:33:26 +01:00
OpenShift Merge Robot 2f5d0d899c
Merge pull request #5334 from edsantiago/bats
kill test: clean up warnings; document better
2020-02-27 11:21:35 +01:00
Ed Santiago 40470b45d3 kill test: clean up warnings; document better
9f69c4eca (part of the f31 pr, #3091) semi-broke the kill test,
there's now an ugly warning:

    setup(): removing stray images quay.io/libpod/fedora-minimal:latest 7bb5a60e8a78

The comments also didn't actually explain the problem
being addressed, and included a misleading reference
to busybox.

Here we switch to using fedora-minimal only with podman-remote,
clean it up (rmi) when finished, and include an explanation in
the comments about why this is needed; making it clear that
this workaround can be removed once we get rid of podman-remote.
We also reformat back to 80 columns.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-02-26 11:01:38 -07:00
OpenShift Merge Robot 19016f3cd8
Merge pull request #5332 from giuseppe/uts-lookup-container
spec: allow container alias name in lookup
2020-02-26 16:58:27 +01:00
OpenShift Merge Robot 75d0d48d20
Merge pull request #5330 from baude/flakefixesfored
curb flakes in integration tests
2020-02-26 16:17:34 +01:00
Brent Baude 04f1306c87 curb flakes in integration tests
instead of searching the fedora registry which is error prone, we instead search a local registry for the empty set search.

when running two containers with the same IP, i suspect the first container has not fully gotten its ip information back from cni when the second container fires.  rework this test such that we use nginx to make sure the container is up and running before continues which should pace the subsequent test.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-02-26 08:30:28 -06:00
Giuseppe Scrivano 418dee100b
spec: allow container alias name in lookup
Previously --uts=container: expected the full container ID.

Closes: https://github.com/containers/libpod/issues/5289

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-02-26 15:04:31 +01:00
OpenShift Merge Robot dd289950de
Merge pull request #5329 from baude/contribspecepoch
add epoch for specfile
2020-02-26 00:39:33 +01:00
OpenShift Merge Robot 9631c30ce4
Merge pull request #5328 from lsm5/trivial-typo-correction
fix trivial typo
2020-02-25 22:57:53 +01:00
Brent Baude 90d70f2cbf add epoch for specfile
to get the copr rpms to jive better with the fedora rpms, we need to set an epoch.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-02-25 15:02:39 -06:00
Lokesh Mandvekar 4e015cefc2 fix trivial typo
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2020-02-25 15:44:06 -05:00
OpenShift Merge Robot 609407d4e6
Merge pull request #5326 from jwhonce/issues/5311
Remove 1 sec delay
2020-02-25 21:32:28 +01:00
OpenShift Merge Robot 6c5591ed9d
Merge pull request #3901 from cevich/support_f31
Cirrus: Support testing with F31
2020-02-25 21:32:20 +01:00
OpenShift Merge Robot 6a03a9a538
Merge pull request #5324 from giuseppe/fix-running-no-pause
rootless: raise error if the process is not found
2020-02-25 21:16:26 +01:00
OpenShift Merge Robot 72fdccda7a
Merge pull request #5323 from giuseppe/rootless-join-fixes
rootless: fix segfault when open fd >= FD_SETSIZE
2020-02-25 21:16:19 +01:00
OpenShift Merge Robot 930ae43e8d
Merge pull request #5313 from edsantiago/test_apiv2
apiv2 tests: add more pod tests, timing check
2020-02-25 21:16:11 +01:00
OpenShift Merge Robot d3aa64c77c
Merge pull request #5312 from raukadah/fixfedora30
Fixed build_rpm.sh script for Fedora 30
2020-02-25 20:04:16 +01:00
Matthew Heon f9fc9a7b7b Add support for multiple CNI networks in podman inspect
When inspecting containers, info on CNI networks added to the
container by name (e.g. --net=name1) should be displayed
separately from the configuration of the default network, in a
separate map called Networks.

This patch adds this separation, improving our Docker
compatibility and also adding the ability to see if a container
has more than one IPv4 and IPv6 address and more than one MAC
address.

Fixes #4907

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-02-25 13:20:25 -05:00
Jhon Honce 997e3c8863 Remove 1 sec delay
* Stop closing net.Listener() twice on interrupt
 * Do not report error if closing server twice

Fixes #5311

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2020-02-25 11:04:20 -07:00
Chris Evich 80da73f13c
Temp. skip "remove pause by id" bindings test
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:26 -05:00
Chris Evich 4511e15f8c
Fix kill test obtaining CID
It's possible/likely the container image for the test will need to be
pulled as part of the `run` command.  Due to the way BATS handles
output, messages regarding image-pull could be misinterpreted as the
container's CID.  Force the CID to be obtained by only the last line of
output.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:26 -05:00
Chris Evich 9f69c4ecaf
System Tests: Force default signal handlers
Recommended as part of:
https://github.com/containers/libpod/issues/5004

and

https://github.com/containers/crun/issues/230

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:26 -05:00
Chris Evich 9b9789c207
Fix cgroupsv2 run test, unexpected output
Sometime between 10th and 23rd of Feb. 2020, the behavior of crun
changed.  Upon consulting with Giuseppe, the podman run tests for
`device-read-*` and `device-write-*` do not depend on the container
output for success, only the exit code.  Add a comment and conditional
regarding this in case of cgroupsv2.  Also noted that these tests
will likely require future refactoring/simplification.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:26 -05:00
Chris Evich 5973641404
Cirrus: SELinux Enforcing for F31 w/ CGv2
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:26 -05:00
Chris Evich 7e95e1e25c
Cirrus: collect podman system info
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:25 -05:00
Chris Evich 0ac0e6e612
Cirrus: F31: Force systemd cgroup mgr
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:25 -05:00
Chris Evich eae42ab256
Cirrus: Temp. disable F31 p-in-p testing
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:25 -05:00
Chris Evich 614917d6aa
Cirrus: Handle runc->crun when both are possible
In some distributions it's possible to have both runc and crun
installed and/or for podman to be confused about which to use.  In these
instances, force the decision by adding `OCI_RUNTIME=/usr/bin/crun` into
`/etc/environment`. Also in-place modify libpod.conf to use 'crun'
instead of 'runc'

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:25 -05:00
Chris Evich 70b28bc2cc
Cirrus: Use deadline elevator in F31
The default scheduler is BFQ but integration tests run into

https://bugzilla.redhat.com/show_bug.cgi?id=1767539
aka
https://bugzilla.kernel.org/show_bug.cgi?id=205447

Using the deadline elevator as a workaround.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:25 -05:00
Chris Evich e0ca4a2260
Cirrus: Support testing with F31
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-02-25 12:34:24 -05:00
Giuseppe Scrivano 6dbb89e56c
rootless: become root only if the pause file is specified
we need to store the pause process PID file so that it can be re-used
later.

commit e9dc212092 introduced this
regression.

Closes: https://github.com/containers/libpod/issues/5246

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-02-25 18:15:29 +01:00
Giuseppe Scrivano d400f0b5b2
rootless: fix segfault when open fd >= FD_SETSIZE
if there are more than FD_SETSIZE open fds passed down to the Podman
process, the initialization code could crash as it attempts to store
them into a fd_set.  Use an array of fd_set structs, each of them
holding only FD_SETSIZE file descriptors.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-02-25 17:52:06 +01:00
OpenShift Merge Robot 3d37dc639d
Merge pull request #5297 from rhatdan/vendor
Update vendor of buildah and containers/common
2020-02-25 15:43:25 +01:00
Ed Santiago f25c595cb8 apiv2 tests: add more pod tests, timing check
Looks like /libpod/pods/create has been fixed to return an
actual pod ID. Extend those tests.

Also, update timeout in the server command: it's now seconds,
not milliseconds.

Also, update FIXME comments in /pods/prune . Still doesn't
work, but clarify what we're seeing.

Also, add a new test that runs ten /info requests and
barfs if it takes more than 5 seconds.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-02-25 06:42:27 -07:00
OpenShift Merge Robot 6babc9f20c
Merge pull request #5305 from mheon/check_for_common_deadlocks
Add basic deadlock detection for container start/remove
2020-02-25 13:17:12 +01:00
Daniel J Walsh 68c313911e
Update vendor of buildah and containers/common
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-02-25 07:46:20 -04:00
OpenShift Merge Robot 8a30759b6b
Merge pull request #5318 from giuseppe/fix-running-without-env-variables
build: move initialization after SetXdgDirs
2020-02-25 01:59:01 +01:00
OpenShift Merge Robot 53b67401b9
Merge pull request #5317 from baude/docsalways
always run the docs task on post-merge
2020-02-24 23:45:55 +01:00
Giuseppe Scrivano 1e94c2964d
build: move initialization after SetXdgDirs
otherwise it triggers the config file initialization from
vendor/github.com/containers/common/pkg/config before the init() in
main.go can set correctly XDG_RUNTIME_DIR and DBUS_SESSION_BUS_ADDRESS
when they are missing.

commit 96de762eed introduced the
regression.

Closes: https://github.com/containers/libpod/issues/5314

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-02-24 22:39:19 +01:00
OpenShift Merge Robot 6c8b523825
Merge pull request #5308 from lsm5/tests-apiv2
add apiv2 tests for podman pause and stop
2020-02-24 22:01:10 +01:00
Giuseppe Scrivano 44baab0a70
utils: relax check for directory to use
when we use namespaces, we set the run directory to 0711 to allow
other users to access it.

without this relaxation, the /run/user/$UID directory would be
skipped.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2020-02-24 21:26:16 +01:00
Lokesh Mandvekar e3857800d2 add apiv2 tests for podman pause and stop
Initial ginkgo setup credit to Brent Baude <bbaude@redhat.com>

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2020-02-24 15:05:52 -05:00
Brent Baude ec82cd30b2 always run the docs task on post-merge
Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-02-24 13:25:46 -06:00
Chandan Kumar (raukadah) 9f6fc70110 Fixed build_rpm.sh script for Fedora 30
golang-github-cpuguy83-go-md2man is only available in Fedora 30 and
got renamed to golang-github-cpuguy83-md2man for Fedora 31 which breaks
the user interface for building rpm on fedora 30.

It fixes the same by installing correct md2man package on Fedora 30.

Signed-off-by: Chandan Kumar (raukadah) <raukadah@gmail.com>
2020-02-24 22:17:21 +05:30
OpenShift Merge Robot afd5cbff1e
Merge pull request #5281 from baude/bindingsci
enable ci on go binding tests
2020-02-24 17:25:22 +01:00
OpenShift Merge Robot 2602083f62
Merge pull request #5301 from baude/apiv2imagetests3
more image binding tests
2020-02-24 17:09:24 +01:00
Matthew Heon 4004f646cd Add basic deadlock detection for container start/remove
We can easily tell if we're going to deadlock by comparing lock
IDs before actually taking the lock. Add a few checks for this in
common places where deadlocks might occur.

This does not yet cover pod operations, where detection is more
difficult (and costly) due to the number of locks being involved
being higher than 2.

Also, add some error wrapping on the Podman side, so we can tell
people to use `system renumber` when it occurs.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-02-24 09:29:34 -05:00