20625 Commits

Author SHA1 Message Date
c1980a6a26 Merge pull request #20409 from Luap99/port-fw
[CI:DOCS] network: document ports and macvlan interaction
2023-10-19 19:48:37 +00:00
85e8aa4e83 Merge pull request #20413 from Luap99/quadlet-cgroupv2
[CI:DOCS] quadlet: document cgroupv2 requirement
2023-10-19 18:45:23 +00:00
ca9efb0cda network: document ports and macvlan interaction
The network backend will ignore ports for macvlan and ipvlan networks so
they do not do anything. No warning or error is shown because containers
may be later connected to a bridge network in which case they would be
useful.

Fixes #17927

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-19 17:04:29 +02:00
f2bc638944 quadlet: document cgroupv2 requirement
Units created with quadlet need cgroupv2 in order to work.

Fixes #19365

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-19 16:39:55 +02:00
0b0f128bfb Merge pull request #20410 from containers/renovate/actions-checkout-digest
[skip-ci] Update actions/checkout digest to b4ffde6
2023-10-19 12:44:12 +00:00
e8183e836c [skip-ci] Update actions/checkout digest to b4ffde6
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-10-19 11:14:37 +00:00
30b14b33ae Merge pull request #20403 from containers/renovate/k8s.io-kubernetes-1.x
fix(deps): update module k8s.io/kubernetes to v1.28.3
2023-10-19 09:34:09 +00:00
c2e1debe8d Merge pull request #20395 from rhatdan/quadlet
Allow systemd specifiers in User and Group Quadlet keys
2023-10-19 09:28:12 +00:00
d1086281bb fix(deps): update module k8s.io/kubernetes to v1.28.3
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-10-19 07:44:35 +00:00
68636416d7 Merge pull request #20357 from rhatdan/TERM
Add TERM iff TERM not defined in container when podman exec -t
2023-10-18 23:50:41 +00:00
b2192695bc Merge pull request #20406 from edsantiago/systest_bork
System tests: fix broken silence127
2023-10-18 22:16:28 +00:00
657029da78 System tests: fix broken silence127
Followup to #20394. For years (since BATS 1.5) we've been
seeing and ignoring nasty red warnings at the end of every
system test run. Thanks for fixing it, @giuseppe! But it
broke down in the '?' case when $expected_rc is empty:

   test/system/helpers.bash: line 345: [: -eq: unary operator expected

Simple fix.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-10-18 14:33:25 -06:00
9a29eb05ef Merge pull request #20400 from baude/issue20361
Fix path for omvf vars on Darwin/arm64
2023-10-18 20:07:53 +00:00
b72bb11629 Add TERM iff TERM not defined in container when podman exec -t
Fixes: https://github.com/containers/podman/issues/20334

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-10-18 15:40:52 -04:00
d4086f5ac4 Merge pull request #20404 from edsantiago/emergency_ci_fix
Emergency workaround for CI breakage
2023-10-18 19:24:38 +00:00
6c7104c4fe Merge pull request #20402 from baude/applehvrmstopgvproxy
Kill gvproxy when machine rm -f
2023-10-18 19:18:32 +00:00
44ed415b25 Emergency workaround for CI breakage
Skip new exec-leak test

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-10-18 12:07:55 -06:00
62a81a166a Merge pull request #20383 from Luap99/init-path
use FindInitBinary() for init binary
2023-10-18 17:17:59 +00:00
d4d76479c1 Kill gvproxy when machine rm -f
In applehv, we were not killing gvproxy when stopping via podman machine rm with force.

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2023-10-18 12:12:23 -05:00
cad4d0ee9f Fix path for omvf vars on Darwin/arm64
On darwin arm64, we need to set the location of the ovmf vars. It should be put into the imageDir (also known as as dataDir).  But because qemu determines the image path late in Init(), the image path is set something like a stream marker.

Fixes #20361

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2023-10-18 10:40:08 -05:00
c73e99aabe Merge pull request #20397 from edsantiago/cp_test_cleanup
systests: cp test: lots of cleanup
2023-10-18 15:07:45 +00:00
553cfb6b63 Merge pull request #20368 from ygalblum/quadlet-image-name
Quadlet - support ImageName for .image files
2023-10-18 14:08:56 +00:00
aabe5c8aa5 Merge pull request #20394 from giuseppe/cleanup-exec-session-on-errors
exec: do not leak session IDs on errors
2023-10-18 13:52:12 +00:00
02757ab20d Merge pull request #20391 from sstosh/nanocpu-api-test
test/apiv2/20-containers.at: fix NanoCPUs tests on cgroups v1
2023-10-18 13:39:18 +00:00
285718915c Allow systemd specifiers in User and Group Quadlet keys
Replaces: https://github.com/containers/podman/pull/18262

Signed-off-by: Tom Mombourquette <tom@devnode.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-10-18 09:23:35 -04:00
caef657c5b libpod: rename confusing import name
The packge is called slirp4netns and renaming it makes no sense, this
was likely done by accident.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-18 15:14:23 +02:00
efe5e98d06 use FindInitBinary() for init binary
Use the new FindInitBinary() function to lookup the init binary, this
allows the use of helper_binaries_dir in contianers.conf[1]

[NO NEW TESTS NEEDED]

[1] https://github.com/containers/common/issues/1110

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-18 15:14:22 +02:00
1d3ec78e00 vendor latest c/common
Includes init path changes.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-18 15:14:13 +02:00
fa19e1baa2 exec: do not leak session IDs on errors
always cleanup the exec session when the command specified to the
"exec" is not found.

Closes: https://github.com/containers/podman/issues/20392

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-10-18 15:02:22 +02:00
1efcd1ecfb systests: cp test: lots of cleanup
cp tests flake constantly under VFS (discovered in #20161),
and the way these tests were written makes it very, very hard
to understand failures.

This is a (sorry) hard-to-review cleanup:

 - use distinctive container names, not just "cpcontainer"
 - add distinctive test names (e.g. RUNNING vs CREATED)
 - remove unnecessary code
 - remove --pause=false (option is deprecated and, IIUC, a NOP)
 - clean up some confusing slashes in paths
 - "dot notation" tests:
   - add a comment linking to issue, because that's a weird one
     that makes no sense whatsoever
   - fix tests, because they were actually not testing

This cleanup has been tested repeatedly in 20161, I'm just bringing
it into main because 20161's future is uncertain.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-10-18 06:47:18 -06:00
9b8e01efd6 Quadlet - support ImageName for .image files
Allow overriding the image name resolved from the .image file
Add test and doc

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-10-18 13:43:54 +03:00
ef2392f21c Merge pull request #20381 from vrothberg/fix-20375
image history: fix walking layers
2023-10-18 10:37:48 +00:00
64171043ac test/system: ignore 127 if it is the expected rc
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2023-10-18 12:24:05 +02:00
a1982c043d Merge pull request #20365 from p-fruck/fix/api-compat-network-connected
fix(API): Catch ErrNetworkConnected for compat
2023-10-18 08:55:31 +00:00
074a0de7f9 Merge pull request #20388 from cevich/cross_target_comment
[CI:DOCS] Add cross-build target info.
2023-10-18 08:41:06 +00:00
c65d1c02b9 test/apiv2/20-containers.at: fix NanoCPUs tests on cgroups v1
* rootful: NanoCpus needs to set more than 10000000 on cgroups v1.
* rootless: Resource limits that include NanoCPUs are not supported and ignored.

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2023-10-18 16:56:18 +09:00
6624ccb4b1 Merge pull request #20384 from Luap99/double-netns
libpod: restart+userns cleanup netns correctly
2023-10-18 07:47:02 +00:00
9394171cbb Merge pull request #20387 from Luap99/machine-doc
[CI:DOCS] machine set: document --rootful better
2023-10-18 07:45:06 +00:00
831844b596 image history: fix walking layers
libimage did not walk thte layers correctly which was probably
inherited by old Podman code.  Fix that by vendoring in the
corresponding changes in c/common.

Fixes: #20375
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-10-18 09:19:24 +02:00
ad53190253 fix(api): Ensure compatibality for network connect
When trying to connect a container to a network and the connection
already exists, an error should only be raised if the container is
already running (or is in the `ContainerStateCreated` transition)
to mimic the behavior of Docker as described here:
https://github.com/containers/podman/pull/15516#issuecomment-1229265942
For running and connected containers 403 is returned which fixes #20365

Signed-off-by: Philipp Fruck <dev@p-fruck.de>
2023-10-17 22:56:32 +02:00
b0a45a905b Merge pull request #20366 from ygalblum/quadlet-kube-down-force
Quadlet - add support for KubeDownForce
2023-10-17 19:50:45 +00:00
91264e7d2e Merge pull request #19586 from rhatdan/ps
Fix output of podman --remote top
2023-10-17 19:12:27 +00:00
c909afb883 Merge pull request #20239 from jackgris/docker-api-error-response
fix: pull error response docker rest api compatibility
2023-10-17 18:51:37 +00:00
e0561301c9 [CI:DOCS] Add cross-build target info.
In case a future maintainer asks "why" all these weird looking
four-letter architectures are present here and in CI.

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-10-17 14:23:21 -04:00
dc705d3702 machine set: document --rootful better
If you change this option all the containers disappear from the default
connection and socket. Thus it is required to recreate the resources.
Sharing between root and rootless is not possible for various reasons.

Fixes #19936

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-17 18:09:13 +02:00
bbd6281ecc libpod: restart+userns cleanup netns correctly
When a userns and netns is used we need to let the runtime create the
netns otherwise the netns is not owned by the right userns and thus
the capabilities would not be correct.

The current restart logic tries to reuse the netns which is fine if no
userns is used but when one is used we setup a new netns (which is
correct) but forgot to cleanup the old netns. This resulted in leaked
network namespaces and because no teardown was ever called leaked ipam
assignments, thus a quickly restarting container will run out of ip
space very fast.

Fixes #18615

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-10-17 17:25:50 +02:00
3b6a4ac37a Minor log and doc fixes
Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-10-17 14:43:02 +03:00
f875ae3176 Quadlet man page - discuss volume removal explicitly
Co-authored-by: Valentin Rothberg <vrothberg@redhat.com>
Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-10-17 14:43:02 +03:00
5d5facbd79 Quadlet - add support for KubeDownForce
Allow users to set --force for Stop command
Add doc and tests

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-10-17 14:43:01 +03:00
5853e2bee9 Merge pull request #20363 from ygalblum/quadlet-kube-oneshot-test
System Test - Quadlet kube oneshot
2023-10-17 10:53:40 +00:00