589 Commits

Author SHA1 Message Date
20345b1ec0 Revert "Change Varlink systemd unit to use system service"
This reverts commit 1bc992bfc3a983b4d9ab53f778a545d83bcde94d.

We originally thought `podman varlink` was entirely removed, but
that was not true. We originally thought that
`podman system service --varlink` worked the same as
`podman varlink` but that was also not true. `system service` is
broken when used under systemd units, and `podman varlink` still
exists and works. Revert the change to `podman system service` to
fix socket-activated Varlink under systemd.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-06-16 11:09:48 -04:00
5a6a3f81a4 Merge pull request #6608 from mheon/fix_varlink_unit
[CI:DOCS] Change Varlink systemd unit to use `system service`
2020-06-15 09:54:53 -04:00
1bc992bfc3 Change Varlink systemd unit to use system service
We completely removed `podman varlink`, which broke the systemd
unit file used by the Varlink code. Change that to use the new
`podman system service --varlink` command which replaced it.

Also needs a slight reorder of args to make things work happily
on my system.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-06-15 09:22:45 -04:00
2ffb703d1b Fix builds for RDO
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-11 08:55:19 -04:00
c44992827d Merge pull request #6530 from edsantiago/test_podman_remote
Enable, then partially disable, podman-remote testing
2020-06-10 13:19:44 -04:00
9967f28339 Merge pull request #6193 from cevich/conmon_ci_packages
Cirrus: Include packages for containers/conmon CI
2020-06-09 21:22:17 -04:00
455a94d1f9 Cirrus: Include packages for containers/conmon CI
This allows the containers/conmon repository to share the same VM
images produced by containers/libpod.  Included are several packages
which are downloaded only since they might otherwise interfere with
testing for some repos.  This allows stable versions to be at the ready
at testing runtime, avoiding any version updates surprising developers.

Also, re-enable running the VM-image check test which was not working
due to a logic problem in Cirrus-CI configuration.  Update the neglected
tests so that they pass on all distros.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-06-09 14:47:23 -04:00
15f273b931 WIP: Enable (and disable) remote testing
podman-remote has not been tested. A principal part of the
problem was #5387 - the YAML I wrote did not have the
intended effect, it did not set TEST_REMOTE_CLIENT=true
and because of my multiple iterations I did not catch this
during testing.

Part 1 of this PR is to fix .cirrus.yml to enable remote tests.

Part 2 -- what I had first noticed and tried to fix -- is that
rootless_test.sh was never running remote because, of course,
envariables are not sent via ssh. I reworked integration_test.sh
and rootless_test.sh to use a command-line decision instead.

Part 3, sigh, is to disable one failing integration test
and *all* system tests, because so many of the latter are
failing. Addressing those failures needs to be done in
subsequent PRs. Issues #6538, #6539, #6540 are filed for
some of the problems I isolated. There will be more.

Also, minor, fixed some stale references to varlink.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-06-09 12:43:58 -06:00
c831ae110e Merge pull request #6521 from cevich/update_cors_docs
[CI:DOCS] Improve swagger+CORS metadata docs
2020-06-09 16:43:32 +02:00
4314336ce3 Improve swagger+CORS metadata docs
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-06-09 09:53:19 -04:00
b6148b6576 force bats version to v1.1.0
We experienced regression when using the latest `v1.2.0-dev` bats in
Ubuntu 20.04 (see github.com/containers/libpod/pull/6418).  Using
bats v1.1.0 worked in the Ubuntu test VM.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-06-08 15:21:34 +02:00
efd1422143 Enable Ubuntu tests in CI
Add updates required for ubuntu and run integration tests

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-06-08 12:21:16 +02:00
77b8187ea0 Attempt to turn on special_testing_in_podman tests
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-04 10:58:37 -04:00
545aef7d9b Vendor in container/storage v1.20.2
Also modify gate Dockerfile to take advantage of skipping
mounting of the storage directory.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-03 17:22:49 -04:00
48d2bea1a3 RHEL8 and Centos8 don't have oci-runtime yet
For the time being we need to just require runc
this should fix rdoproject.org/github-check

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-06-03 06:32:58 -04:00
69020c7040 Bump Conmon in COPR spec
We need 2.0.17 for detached remote exec.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 15:30:42 -04:00
e0d9404634 Enable detached exec for remote
The biggest obstacle here was cleanup - we needed a way to remove
detached exec sessions after they exited, but there's no way to
tell if an exec session will be attached or detached when it's
created, and that's when we must add the exit command that would
do the removal. The solution was adding a delay to the exit
command (5 minutes), which gives sufficient time for attached
exec sessions to retrieve the exit code of the session after it
exits, but still guarantees that they will be removed, even for
detached sessions. This requires Conmon 2.0.17, which has the new
`--exit-delay` flag.

As part of the exit command rework, we can drop the hack we were
using to clean up exec sessions (remove them as part of inspect).
This is a lot cleaner, and I'm a lot happier about it.

Otherwise, this is just plumbing - we need a bindings call for
detached exec, and that needed to be added to the tunnel mode
backend for entities.

Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2020-06-02 15:30:42 -04:00
8a914e8a0b default build without varlink tag
Issue gh#6286 was already fixed in a prior commit but the Makefile still
ran some varlink steps by default.

This commit makes any varlink build steps dependent on the varlink
build tag and also makes the contrib rpm spec file independent of
varlink.

Endpoint tests will be run only if BUILDTAGS contains varlink.

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2020-05-29 14:38:33 -04:00
dc80267b59 compat handlers: add X-Registry-Auth header support
* Support the `X-Registry-Auth` http-request header.

 * The content of the header is a base64 encoded JSON payload which can
   either be a single auth config or a map of auth configs (user+pw or
   token) with the corresponding registries being the keys.  Vanilla
   Docker, projectatomic Docker and the bindings are transparantly
   supported.

 * Add a hidden `--registries-conf` flag.  Buildah exposes the same
   flag, mostly for testing purposes.

 * Do all credential parsing in the client (i.e., `cmd/podman`) pass
   the username and password in the backend instead of unparsed
   credentials.

 * Add a `pkg/auth` which handles most of the heavy lifting.

 * Go through the authentication-handling code of most commands, bindings
   and endpoints.  Migrate them to the new code and fix issues as seen.
   A final evaluation and more tests is still required *after* this
   change.

 * The manifest-push endpoint is missing certain parameters and should
   use the ABI function instead.  Adding auth-support isn't really
   possible without these parts working.

 * The container commands and endpoints (i.e., create and run) have not
   been changed yet.  The APIs don't yet account for the authfile.

 * Add authentication tests to `pkg/bindings`.

Fixes: #6384
Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
2020-05-29 15:39:37 +02:00
154debb804 Fix Dockerfile
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-05-26 09:53:27 -04:00
ab0681380f [CI:DOCS] Prepare image to turn on podman-commands test
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-05-23 10:17:31 -04:00
4d826f0d0c [CI:DOCS]add crun to gating image
the gating tests for commands needs crun to exercise itself

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-05-22 14:46:06 -05:00
b21f342b5b [CI:DOCS]Add conmon to gating image
the gating image now needs conmon to perform the commands check

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-05-22 12:38:04 -05:00
8d54e4855c Cirrus: Fix image-name hints
This properly prints out image-name hints when executing the hack script
without any arguments.  It is required due to changes made by Ed for
test-name beatification.  An identical change was made and reviewed by
Ed in the containers/storage repo.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-05-14 15:00:34 -04:00
6479b54f41 Cirrus: Update Ubuntu 18 to 20
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-05-14 15:00:34 -04:00
837b80bc07 Default podman.spec to use crun
On systems with cgroupV2 runc will not currently work
switch the default in spec file to use crun.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-05-14 09:38:29 -04:00
b5ea00b4f7 [CI:DOCS]remove libpod.conf from spec
in the contrib rpm.spec.in, we no longer should try to package libpod.conf

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-05-13 11:54:34 -05:00
440e97c2c0 Remove libpod.conf from repo
Now that we're shipping containers.conf, we don't want to provide
a libpod.conf anymore. This removes libpod.conf from the repo and
as many direct uses as I can find.

There are a few more mentions in the documentation, but someone
more familiar with containers.conf should make those edits.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-05-12 14:15:44 -04:00
a4c607cc71 set binding tests to required
some small fix ups for binding tests and then make them required.

update containers-common

V2 bindings tests were failing because of changes introduced in commit
a2ad5bb.

Fix some typos.

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>

in the case where the specgen attribute for Env and Labels are nil, we should should then make the map IF we have labels and envs that need to be added.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2020-05-08 09:05:37 -05:00
50cb32fdfb CI:DOCS: Document API docs + CORS maintenance
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-05-06 15:52:53 -04:00
36d36ec2a4 [CI:DOC]Use full repo name in podmanimage Dockerfiles
In the Buildah images, we had a problem where the testing image
was installed with an older version of Buildah than the stable
image.  This was apparently due to quay.io using Docker and Dockerhub
which has a version of Fedora that did not let testing
version of Buildah to be installed as it should have been.

This change fully specifies the name of the fedora image to
use.  This has not been a problem in Podman, but I'm carrying
this change here to avoid future problems.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2020-05-01 17:54:33 -04:00
6e60772dc3 Cirrus: Utilize new base images
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-30 13:21:03 -04:00
7c44c05425 cirrus: Update to Fedora 32 proper
Now that it's officially released, update to it from the beta.  Also
(and significant), adjust the SELinux context of the GCP metadata
service.  Add a comment to the code explaining why this is necessary.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-30 13:21:03 -04:00
d1196d08d0 Merge pull request #6010 from TomSweeneyRedHat/dev/tsweeney/ctrimagefixes
Update podmanimage files to adjust perms on containers.conf for rootless
2020-04-29 16:59:37 +02:00
620baafa07 Merge pull request #5853 from cevich/unify_in_podman_build
Unify in_podman container packaging & VM packaging
2020-04-29 16:38:24 +02:00
9229312f2a Update podmanimage files to adjust perms on containers.conf for rootless
Adding the changes to the Podman image Docker/Containerfiles similar
to @rhatdan 's changes in https://github.com/containers/buildah/pull/2332

In short it changes the perms on containers.conf so it can be used by a
rootless user.

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2020-04-28 17:52:14 -04:00
97ecd21b59 Cirrus: Unify package installation
Also, test-build critical container images depended upon for
CI-purposes.

Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-24 08:22:50 -04:00
c10bd7c11f Makefile: include -nobuild install targets
Distro packaging often uses non-default build and linker flags.
The current Makefile cannot be used in the package build process as it
will end up rebuilding the binaries with the default flags.

This commit introduces install targets which do not depend on the build
targets. Distro packages should prefer these if they want to use any
non-default flags.

NOTE: This commit effectively leaves prior targets unchanged, so users
won't notice any difference.

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2020-04-23 13:08:25 -04:00
5bbbc9996f Merge pull request #5737 from cevich/add_f32
Cirrus: Add support for Fedora 32 beta
2020-04-22 07:37:14 -04:00
ea63f7076a Merge pull request #5909 from abitrolly/patch-2
gate/README.md  Fix link to .cirrus.yml and reword
2020-04-21 18:45:25 -04:00
62b54dd7c4 gate/README.md Fix link to .cirrus.yml and reword
Signed-off-by: Anatoli Babenia <anatoli@rainforce.org>
2020-04-21 17:21:04 +03:00
84bbdcef5d Merge pull request #5910 from abitrolly/shared-deps
Move Fedora 31 dependencies for building podman into separate file
2020-04-21 09:08:45 -04:00
05a5184302 Move Fedora dependencies for building podman into separate file
This ones listed here are actual for Fedora 31.

Signed-off-by: Anatoli Babenia <anatoli@rainforce.org>
2020-04-21 14:58:37 +03:00
532c7343a9 Add support for containers.conf to podmanimages
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-04-20 16:11:49 -04:00
d2d9722454 Cirrus: Add support for Fedora 32
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-20 14:22:23 -04:00
e282c88d2c Cirrus: More Ubuntu 19 + Fedora 31
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-20 14:22:23 -04:00
1be8a34f5e Log formatter: add BATS summary line
BATS emits a summary line (number of tests passed/failed)...
but only on a tty or when run with --pretty! In our CI
context, with TAP output, it gives no end summary.

Fix that. Keep track of 'ok', 'not ok', and 'skipped',
and display the counts at the end.

Also: add a regression test. You don't need to review
or even read it: it's stark, and I'm not even enabling
it for CI because it almost certainly won't run due to
missing Perl library modules. It's just something I
need on my end.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-04-17 08:12:09 -06:00
e394ff407c Cirrus: Fix gate container build failure
Signed-off-by: Chris Evich <cevich@redhat.com>
2020-04-15 13:51:25 -04:00
2aca1b7f9b logformat: handle apiv2 results, add anchor links
apiv2 tests emit TAP-compliant output; recognize it and
highlight it the same way we do BATS tests.

Add anchor links to TAP output, so other tools (e.g.
cirrus-flake-summarize) can link to particular lines

And, remove a "-f" from "wait" in test-apiv2; looks
like there's some version of bash used in some CI VM
that doesn't grok it.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2020-04-15 13:51:25 -04:00
4489440aaf Bump to v2.0.0-dev
Signed-off-by: Matthew Heon <mheon@redhat.com>
2020-04-15 10:51:33 -04:00