19014 Commits

Author SHA1 Message Date
e7ef259cb6 Merge pull request #18671 from vrothberg/RUN-1776
kube play: add exit-code propagation
2023-05-26 04:57:24 -04:00
0357881075 Merge pull request #18687 from lsm5/packit-downstream-followup
[CI:BUILD] Packit: set propose-downstream action type to pre-sync
2023-05-25 12:38:46 -04:00
85b4c896bd [CI:BUILD] Packit: set propose-downstream action type to pre-sync
Also address review concerns in pr#18675.

[NO NEW TESTS NEEDED]

Co-authored-by: Chris Evich <cevich@redhat.com>
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-05-25 09:26:35 -04:00
8f94a4775a [CI:DOCS] fix Quadlet man page rendering
Fixes: https://github.com/containers/podman/pull/18671#pullrequestreview-1442193542
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-25 14:46:35 +02:00
29f7c494ee Quadlet: kube: use ExecStopPost
Use ExecStopPost instead of ExecStop to make sure containers, pods, etc.
are all cleaned up even in case of an error.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-25 14:46:35 +02:00
6487d9c11a Quadlet: kube: add ExitCodePropagation field
Add a new field `ExitCodePropagation` field to allow for configuring the
newly added functionality of controlling how the main PID of a kube
service exits.

Jira: issues.redhat.com/browse/RUN-1776
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-25 14:46:35 +02:00
08b0d93ea3 kube play: exit-code propagation
Implement means for reflecting failed containers (i.e., those having
exited non-zero) to better integrate `kube play` with systemd.  The
idea is to have the main PID of `kube play` exit non-zero in a
configurable way such that systemd's restart policies can kick in.

When using the default sdnotify-notify policy, the service container
acts as the main PID to further reduce the resource footprint.  In that
case, before stopping the service container, Podman will lookup the exit
codes of all non-infra containers.  The service will then behave
according to the following three exit-code policies:

 - `none`: exit 0 and ignore containers (default)
 - `any`: exit non-zero if _any_ container did
 - `all`: exit non-zero if _all_ containers did

The upper values can be passed via a hidden `kube play
--service-exit-code-propagation` flag which can be used by tests and
later on by Quadlet.

In case Podman acts as the main PID (i.e., when at least one container
runs with an sdnotify-policy other than "ignore"), Podman will continue
to wait for the service container to exit and reflect its exit code.

Note that this commit also fixes a long-standing annoyance of the
service container exiting non-zero.  The underlying issue was that the
service container had been stopped with SIGKILL instead of SIGTERM and
hence exited non-zero.  Fixing that was a prerequisite for the exit-code
propagation to work but also improves the integration of `kube play`
with systemd and hence Quadlet with systemd.

Jira: issues.redhat.com/browse/RUN-1776
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-25 14:46:34 +02:00
6dbc138339 prune exit codes only when container doesn't exist
Make sure to prune container exit codes only when the associated
container does not exist anymore.  This is needed when checking if any
container in kube-play exited non-zero and a building block for the
below linked Jira card.

[NO NEW TESTS NEEDED] - there are no unit tests for exit code pruning.

Jira: https://issues.redhat.com/browse/RUN-1776
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-25 13:14:27 +02:00
688e6dbef1 Merge pull request #18640 from HirazawaUi/add-pasta-to-podman-info
podman: Add pasta to podman info
2023-05-25 06:55:04 -04:00
977b3cdbf6 podman: Add pasta to podman info
[NO NEW TESTS NEEDED]

Fixes: #18561

Signed-off-by: binghongtao <695097494plus@gmail.com>
2023-05-25 00:39:52 +08:00
47ac6c4cbe Merge pull request #18674 from edsantiago/revert_17796
Revert "test/system/255-auto-update.bats: add debug logs"
2023-05-24 12:29:01 -04:00
74d804d1ca Merge pull request #18465 from lsm5/packit-downstream-sync
[CI:BUILD] Packit: add jobs for downstream Fedora package builds
2023-05-24 10:53:57 -04:00
373919ca0a Revert "test/system/255-auto-update.bats: add debug logs"
RHEL gating tests failing, because (sigh) journalctl doesn't
work rootless on RHEL.

I think the flake is fixed anyway, so we don't need this.

This reverts commit ba141adce489a0188b91dad36f055607b23b72cc.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-05-24 07:41:57 -06:00
86746c067f Merge pull request #18670 from ygalblum/quadlet-kube-podman-args
Quadlet - add support for PodmanArgs to all groups
2023-05-24 04:43:21 -04:00
901900530a Quadlet - add support for PodmanArgs to all groups
PodmanArgs allows users to pass arguments not explicitly supported by
Quadlet.

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2023-05-24 10:05:02 +03:00
6003dca9c7 [CI:BUILD] Packit: add jobs for downstream Fedora package builds
Get rid of `podman.spec.rpkg` in favour of
`rpm/podman.spec` which gets synced with fedora dist-git on every
upstream release. The version in the new spec file is set to `0` by
default and gets updated by packit automatically on every packit task.

For local manual rpm builds using the spec, the helper script in the
`rpm/` subdir will update the Version field with the latest version
found in the upstream repo.

Packit will automatically create a PR on fedora dist-git on every new
upstream release. A sample PR will look like:
https://src.fedoraproject.org/rpms/container-selinux/pull-request/10#

A dry run for this can be triggered using:
`$ packit propose-downstream --local-content`

To run this command locally, you would need to have your packit
user-configuration-file set.
Ref: https://packit.dev/docs/configuration/#user-configuration-file

along with a fedora api key created at:
https://src.fedoraproject.org/settings#nav-api-tab with sufficient ACLs.

Also includes a revised `package` Makefile target which will build rpms
using `rpm/podman.spec`. Fixes: #18421.

[NO NEW TESTS NEEDED]

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-05-23 16:41:46 -04:00
c08ecd6cb3 Merge pull request #18664 from mtrmac/rm-concurrent-flake
In a concurrent removal test, don't remove concurrently with builds
2023-05-23 16:05:33 -04:00
fb8a124905 In a concurrent removal test, don't remove concurrently with builds
This test is intended to test concurrent removals, so don't
risk a removal breaking a build.

Fixes #18659 .

(The sitaution that removals can break a build WIP is a real
problem that should be fixed, but that's not a target of this test.)

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2023-05-23 18:14:33 +02:00
c894a12b74 Merge pull request #18651 from containers/renovate/requests-2.x
chore(deps): update dependency requests to ~=2.31.0
2023-05-23 07:45:32 -04:00
fe64f79469 Merge pull request #18636 from mtrmac/cleanupStorage-error
Fix, and reduce repetitiveness, in container cleanup error handling
2023-05-23 07:43:01 -04:00
d7b811677e Merge pull request #18652 from anjannath/update-qemu
pkginstaller: bump Qemu to version 8.0.0
2023-05-23 07:11:14 -04:00
acad53ad64 Merge pull request #18653 from edsantiago/unlinkat-ebusy-bail
TEMPORARY(?) instrumentation for unlinkat-ebusy
2023-05-23 06:36:11 -04:00
ca7d0128b2 Merge pull request #18619 from vyasgun/pr/events-volume-name
fix: event --filter volume=vol-name should compare the event name with volume name
2023-05-23 02:42:57 -04:00
032d4a95f0 Consolidate error handling in Runtime.removeContainer
Use a helper to handle the cleanupErr logic instead of
copy&pasting it EIGHT times.

Also modifies the returned errors to be wrapped with a context,
and changes the text of the logged errors a bit.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2023-05-22 19:14:06 +02:00
f556e58bb0 Consolidate error handling in Container.cleanupStorage
Use a shared helper instead of copy&pasting the handling
of cleanupErr EIGHT times.

This changes the wording of logged error text, and the error
in one case, a bit.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2023-05-22 19:14:06 +02:00
4969c552ec Fix reporting errors on container unmount
[NO NEW TESTS NEEDED]
... because testing this would require us to intentionally
create an inconsistent state, which should ideally not be possible...
(and because at this point I don't even know what the reported failure
was.)

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2023-05-22 19:11:56 +02:00
94c65a659c TEMPORARY(?) instrumentation for unlinkat-ebusy
Instrument system tests in hopes of tracking down #17216,
the unlinkat-ebusy-hosed flake.

Oh, also, timestamp.awk: timestamps have always been UTC, but
add a 'Z' to make it unambiguous.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-05-22 10:34:37 -06:00
d623670e1a pkginstaller: bump Qemu to version 8.0.0
this updates the Makefile qemu version to make use new qemu released at
https://github.com/containers/podman-machine-qemu/releases/tag/v8.0.0-1

[NO NEW TESTS NEEDED]

Signed-off-by: Anjan Nath <kaludios@gmail.com>
2023-05-22 21:43:21 +05:30
b15510694b Merge pull request #18649 from Luap99/network-create-dns
network create/update: allow dns servers comma separated
2023-05-22 12:02:08 -04:00
c963844bd9 Merge pull request #18639 from rhatdan/pull
Increase download progress to 80ch
2023-05-22 11:59:30 -04:00
b6a406b8d3 Merge pull request #18622 from containers/renovate/github.com-onsi-gomega-1.x
fix(deps): update module github.com/onsi/gomega to v1.27.7
2023-05-22 11:57:05 -04:00
9969374b6b chore(deps): update dependency requests to ~=2.31.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2023-05-22 15:55:35 +00:00
fcc3f47c7a Merge pull request #18595 from containers/renovate/github.com-docker-docker-24.x
fix(deps): update module github.com/docker/docker to v24
2023-05-22 11:54:12 -04:00
af8d19dc2e Merge pull request #18581 from vrothberg/fix-18572
wait: look for exit code in stopped state
2023-05-22 11:51:14 -04:00
5f29c7bf98 fix: podman event --filter volume=vol-name should compare the event name with volume name
Fixes: https://github.com/containers/podman/issues/18618

Signed-off-by: Gunjan Vyas <vyasgun20@gmail.com>
2023-05-22 19:11:15 +05:30
6b48e9962c fix(deps): update module github.com/docker/docker to v24
Also reflect removed/deprecated fields in the compat API.

[NO NEW TESTS NEEDED]

Signed-off-by: Renovate Bot <bot@renovateapp.com>
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-22 15:32:12 +02:00
1b9272a060 wait: look for exit code in stopped state
Make sure to look for the container's exit code when it's in stopped
state.  With `--restart=always`, the container seems to stay in the
stopped state which led the wait logic to loop until the 20 seconds
timeout for the cleanup process to have finished kicks in.

Also defensively make sure to loop when the container is in stopped
state but no exit code has been written yet.

Add a regression test to make sure Podman doesn't wait more than 20
seconds.  Even on a CI machine under high load I expect it to take much
much much less than that, so I do not expect this test to flake in the
future.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-05-22 14:53:19 +02:00
9252f926e6 Merge pull request #18596 from containers/renovate/github.com-sirupsen-logrus-1.x
fix(deps): update module github.com/sirupsen/logrus to v1.9.2
2023-05-22 08:44:02 -04:00
4003871823 Merge pull request #18625 from Akasurde/docs_fix
Correct markdown in docs
2023-05-22 08:07:45 -04:00
dc67f89b7e Merge pull request #18628 from eriksjolund/quadlet_tests_updates
Quadlet tests: enable device.volume and remove socketactivated.container
2023-05-22 08:02:37 -04:00
5c6d70c884 Merge pull request #18644 from eriksjolund/fix_various_doc_issues
source code comments and docs: fix typos, language, Markdown layout
2023-05-22 07:59:57 -04:00
7d831d555c network create/update: allow dns servers comma separated
The examples show that --dns-add 8.8.8.8,1.1.1.1 is valid but it fails,
fix this by using StringSliceVar which splits at commas.
Added tests to ensure it is working.

Fixes #18632

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-05-22 13:30:39 +02:00
685c736185 source code comments and docs: fix typos, language, Markdown layout
- fix a/an before noun
- fix loose -> lose
- fix "the the"
- fix lets -> let's
- fix Markdown layout
- fix a few typos
- remove unnecessary text in troubleshooting.md

Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-05-22 07:52:16 +02:00
fe41077d44 Increase download progress to 80ch
Fixes: #17718

[NO NEW TESTS NEEDED]

Signed-off-by: Sorin Sbarnea <ssbarnea@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-05-20 07:17:08 -04:00
44807eabf1 Merge pull request #18638 from containers/renovate/setuptools-67.x
chore(deps): update dependency setuptools to ~=67.8.0
2023-05-20 06:20:41 -04:00
a8291227de Merge pull request #18620 from HirazawaUi/find_slirp4netns_from_helper_binaries_dir
podman: Added find slirp4netns binary file from helper_binaries_dir
2023-05-20 06:18:07 -04:00
8fbcf8bce8 chore(deps): update dependency setuptools to ~=67.8.0
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2023-05-19 22:15:28 +00:00
29749362a0 podman: Added find slirp4netns binary file from helper_binaries_dir
[NO NEW TESTS NEEDED]

Fixes: #18568
Signed-off-by: binghongtao <695097494plus@gmail.com>
2023-05-20 03:17:22 +08:00
8d0cde0455 Merge pull request #18630 from giuseppe/fix-mem-limit-stats
stats: get mem limit from the cgroup
2023-05-19 12:25:17 -04:00
2253f709bf fix(deps): update module github.com/sirupsen/logrus to v1.9.2
Signed-off-by: Renovate Bot <bot@renovateapp.com>
2023-05-19 14:36:19 +00:00