Commit graph

14274 commits

Author SHA1 Message Date
tomsweeneyredhat
583fdc76d0 [v4.0]Option --url and --connection should imply --remote
Addresses #13393 and replaces #13357.  Many thanks to
@Romain-Geissler-1A for the initial submission and discussions.

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2022-03-01 19:46:38 -05:00
OpenShift Merge Robot
965d28024c
Merge pull request #13392 from baude/v4reverts
V4reverts
2022-03-01 16:50:38 -05:00
Brent Baude
791c8c347c Revert "use GetRuntimeDir() from c/common"
This reverts commit fc5cf812c8.

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-03-01 13:24:39 -06:00
Brent Baude
cc4a70c806 Revert "Option --url and --connection should imply --remote."
This reverts commit ca980c2e02.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-03-01 13:15:03 -06:00
OpenShift Merge Robot
cff448be2d
Merge pull request #13357 from Romain-Geissler-1A/backport-connection-implies-remote
Option --url and --connection should imply --remote.
2022-02-28 18:45:18 -05:00
Romain Geissler
ca980c2e02 Option --url and --connection should imply --remote.
Closes #13242

Signed-off-by: Romain Geissler <romain.geissler@amadeus.com>
2022-02-26 10:27:34 +00:00
OpenShift Merge Robot
49d511b6ee
Merge pull request #13329 from mheon/bump_401
Bump to v4.0.1
2022-02-23 16:43:02 -05:00
Matthew Heon
cfcc0d6398 Bump to v4.0.2-dev
Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-02-23 14:35:14 -05:00
Matthew Heon
c8b9a2e3ec Bump to v4.0.1
Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-02-23 14:34:57 -05:00
Matthew Heon
b1ffa822f8 Update release notes for v4.0.1
Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-02-23 14:34:34 -05:00
Matthew Heon
de9f228052 Fix a potential flake in volume plugins tests
We could remove the container running the volume plugins, before
the containers using the volume plugins; this could cause
unmounting the volumes to fail because the plugin could not be
contacted.

Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-02-23 14:33:34 -05:00
David Gibson
697dd2890e Propagate $CONTAINERS_CONF to conmon
The CONTAINERS_CONF environment variable can be used to override the
configuration file, which is useful for testing.  However, at the moment
this variable is not propagated to conmon.  That means in particular, that
conmon can't propagate it back to podman when invoking its --exit-command.
The mismatch in configuration between the starting and cleaning up podman
instances can cause a variety of errors.

This patch also adds two related test cases.  One checks explicitly that
the correct CONTAINERS_CONF value appears in conmon's environment.  The
other checks for a possible specific impact of this bug: if we use a
nonstandard name for the runtime (even if its path is just a regular crun),
then the podman container cleanup invoked at container exit will fail.
That has the effect of meaning that a container started with -d --rm won't
be correctly removed once complete.

Fixes #12917

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2022-02-23 14:33:07 -05:00
David Gibson
c559e4e6fb tests: Remove inaccurate comment
This comment refers to overiding $PODMAN although the code below does
nothing of the sort.  Presumbly the comment has been outdated by altering
the containers.conf / $CONTAINERS_CONF instead.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2022-02-23 14:33:00 -05:00
Ed Santiago
3718d096b1 System tests: show one-line config overview
We're running into problems that are impossible to diagnose
because we have no idea if the SUT is using netavark or CNI.
We've previously run into similar problems with runc/crun,
or cgroups 1/2.

This adds a one-line 'echo' with important system info. Now,
when viewing a full test log, it will be possible to view
system settings in one glance.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2022-02-23 14:32:32 -05:00
Paul Holzinger
e1d5c812d0 provide better error on invalid flag
Add a extra `See 'podman command --help'` to the error output.
With this patch you now get:
```
$ podman run -h
Error: flag needs an argument: 'h' in -h
See 'podman run --help'
```

Fixes #13082
Fixes #13002

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-02-23 14:32:05 -05:00
Paul Holzinger
2b85f62a23 use GetRuntimeDir() from c/common
To prevent duplication and potential bugs we should use the same
GetRuntimeDir function that is used in c/common.

[NO NEW TESTS NEEDED]

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-02-23 14:31:39 -05:00
Aditya R
82f4760dea kube: honor --build=false and make --build=true by default
`podman play kube` tries to build images even if `--build` is set to
false so lets honor that and make `--build` , `true` by default so it
matches the original behviour.

Signed-off-by: Aditya R <arajan@redhat.com>
2022-02-23 14:30:25 -05:00
Paul Holzinger
e356dfe06b system tests: cleanup networks on teardown
When a test which creates a network fail it will not remove the network.
The teardown logic should remove the networks. Since there is no --all
option for network rm we use network prune --force.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-02-23 14:30:02 -05:00
Matthew Heon
71b0909f2d Remove the runtime lock
This primarily served to protect us against shutting down the
Libpod runtime while operations (like creating a container) were
happening. However, it was very inconsistently implemented (a lot
of our longer-lived functions, like pulling images, just didn't
implement it at all...) and I'm not sure how much we really care
about this very-specific error case?

Removing it also removes a lot of potential deadlocks, which is
nice.

[NO NEW TESTS NEEDED]

Signed-off-by: Matthew Heon <mheon@redhat.com>
2022-02-23 14:29:41 -05:00
Daniel J Walsh
ee7cf3cc2c Don't log errors on removing volumes inuse, if container --volumes-from
When removing a container created with a --volumes-from a container
created with a built in volume, we complain if the original container
still exists.  Since this is an expected state, we should not complain
about it.

Fixes: https://github.com/containers/podman/issues/12808

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-02-23 14:27:52 -05:00
Giuseppe Scrivano
eb9fe52a55 kube: honor mount propagation mode
convert the propagation mode specified for the mount to the expected
Linux mount option.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2022-02-23 14:26:10 -05:00
Paul Holzinger
a0c34d64a5 Load ip_tables modules at boot
Rootless users cannot load the ip_tables module, in fedora 36 this
module is no longer loaded by default so we have to add it manually.
This is needed because rootless network setup tries to use iptables
and if iptables-legacy is used instead of iptables-nft it will fail.

To provide a better user experience we will load the module at boot.

Note that this is not needed for RHEL because iptables-legacy is not
supported on RHEL 8 and newer.

[NO NEW TESTS NEEDED]

Fixes #12661

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-02-23 14:25:09 -05:00
OpenShift Merge Robot
172b745d0e
Merge pull request #13251 from cevich/new_4.0_vm_images
[v4.0] Cirrus: Update VM Images for 4.0 release
2022-02-19 22:51:31 -05:00
Chris Evich
e8d7e580a9
Cirrus: Disable F34 aka prior-fedora testing
Podman 4.0 will never be supported in F34, and the use of F35 in CI is
temporary until F36 is brought up to speed.  Rather than fight with
testing issues that will never be fixed/supported, simply disable it.
This commit may be reverted at a future date when F36 VM support is
added.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-02-17 16:37:48 -05:00
Chris Evich
7b106f5b6b
Cirrus: Update VM Images for 4.0 release
This is to ensure VM images for CI, which contain the
intended dependency versions to support the podman
4.0 release.

Ref: https://github.com/containers/automation_images/pull/114

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-02-17 16:37:06 -05:00
OpenShift Merge Robot
93e8c39834
Merge pull request #13255 from mheon/bump_400_final
Bump to v4.0.0 final
2022-02-17 14:26:39 -05:00
Matthew Heon
d59749d64d Bump to v4.0.1-dev
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-02-17 12:34:05 -05:00
Matthew Heon
49f8da7271 Bump to v4.0.0
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-02-17 12:34:05 -05:00
Matthew Heon
84c8870ac2 Release notes for v4.0.0 final
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-02-17 12:34:05 -05:00
Matthew Heon
15cb918556 Fix lint
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
2022-02-17 12:34:05 -05:00
Jhon Honce
ae9ad416a3 Fix manifest 4.0 Endpoints
Branch forced 4.0 only endpoints

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2022-02-17 12:34:05 -05:00
Jason T. Greene
1a8c715f1f Introduce podman machine init --root=t|f and podman machine set --root=t|f
Switch default to rootless for mac and windows

Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-02-16 14:02:58 -05:00
Jason T. Greene
f71dfcb5da Initial implementation of mac forwarding using a privileged docker sock claim helper
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-02-16 14:02:52 -05:00
esendjer
2128236da5 ignition: propagate proxy settings from a host into a vm
Set proxy settings (such as `HTTP_PROXY`, and others)
for the whole guest OS with setting up `DefaultEnvironment`
with a `systemd` configuration file `default-env.conf`,
a `profile.d` scenario file - `default-env.sh` and
a `environment.d` configuration file `default-env.conf`

The **actual** environment variables are read by podman
at a start, then they are encrypted with base64 into
a single string and after are provided into a VM through
QEMU Firmware Configuration (fw_cfg) Device

Inside a VM a systemd service `envset-fwcfg.service`
reads the providead encrypted string from fw_cfg, decrypts
and then adds to the files
 - `/etc/systemd/system.conf.d/default-env.conf`
 - `/etc/profile.d/default-env.sh`
 - `/etc/environment.d/default-env.conf`
At the end this service execute  `systemctl daemon-reload`
to propagate new variables for systemd manager

[NO NEW TESTS NEEDED]

Closes #13168

Signed-off-by: esendjer <esendjer@gmail.com>
2022-02-16 14:02:42 -05:00
Jason T. Greene
809da6b0ba Update to podman4 copr stream
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2022-02-16 14:01:20 -05:00
Patrycja Guzik
bd8ac0017e Unify ls --filter docs for networks and pods
Signed-off-by: Patrycja Guzik <patrycja.k.guzik@gmail.com>

#13078 follow-up
2022-02-16 14:00:50 -05:00
Valentin Rothberg
77e51e188c e2e: merge after/since image-filter tests
Merge the two tests to speed up testing.  Both built the exact same
images.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2022-02-16 14:00:30 -05:00
Paul Holzinger
8ad29421eb podman network: add documentation for netavark
Add some docs about the different network backends. Also remove the CNI
word from network since we refer to either a netavark or CNI config.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2022-02-16 14:00:06 -05:00
Morten Linderud
f35e03ec81 create: Fix key=value annotation in the flag output
[NO NEW TESTS NEEDED]

Signed-off-by: Morten Linderud <morten@linderud.pw>
2022-02-16 13:59:36 -05:00
Lokesh Mandvekar
22cfa98605 enable netavark specific tests
These are copies of the CNI tests with modifications wherever
neccessary.

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2022-02-16 13:59:04 -05:00
Adrian Reber
d77b4f92c0 Fix checkpoint/restore pod tests
Checkpoint/restore pod tests are not running with an older runc and now
that runc 1.1.0 appears in the repositories it was detected that the
tests were failing. This was not detected in CI as CI was not using runc
1.1.0 yet.

Signed-off-by: Adrian Reber <areber@redhat.com>
2022-02-16 13:58:40 -05:00
Daniel J Walsh
a72e22160a Make sure building with relative paths work correctly.
Fixes: https://github.com/containers/podman/issues/12763

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-02-16 13:56:39 -05:00
Jhon Honce
975d79aedb Add 409 response to swagger godoc
When attempting to create a network with a name that already exists,
a 409 status code will be returned

[NO NEW TESTS NEEDED]

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2022-02-16 13:55:56 -05:00
OpenShift Merge Robot
a34f27959a
Merge pull request #13233 from baude/v4.0fcosside
[BACKPORT] V4.0fcosside
2022-02-16 13:27:44 -05:00
Brent Baude
421b7466c2 Fix images since/after tests
For the since and after imagve filter tests, instead of using the
read-only cache of images, we just use the empty r/w store.  We then
build three images that are strictly predictable.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-02-16 10:49:43 -06:00
Brent Baude
04badc2c9c Changes of docker descriptions
It looks like some descriptions have changed on the docker registry
where we had been searching for images that include 'alpine'.  We are
now seeing an image in the initial list that has 'alpine' in its
description.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-02-16 10:49:35 -06:00
OpenShift Merge Robot
aa1a6b6eaa
Merge pull request #13249 from baude/backporte2efixes
[BACKPORT] Backporte2efixes
2022-02-16 11:33:43 -05:00
Brent Baude
09708bee9c Fix images since/after tests
For the since and after imagve filter tests, instead of using the
read-only cache of images, we just use the empty r/w store.  We then
build three images that are strictly predictable.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-02-16 08:55:36 -06:00
Brent Baude
35a4f32be6 Changes of docker descriptions
It looks like some descriptions have changed on the docker registry
where we had been searching for images that include 'alpine'.  We are
now seeing an image in the initial list that has 'alpine' in its
description.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-02-16 08:38:50 -06:00
Brent Baude
629d864459 Temporarily pull machine images from side repo
Until podman4 is in the fcos trees, we need to pull the machine images
from a side repository.  There is a hard coded bit that forces the
side repo download right now.  Simple comment or removal of the bit will
revert to normal download behavior.

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2022-02-14 15:10:40 -06:00