Commit graph

17919 commits

Author SHA1 Message Date
Ashley Cui
072ca7cdab Release notes for v4.4.4
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-03-27 13:36:01 -04:00
OpenShift Merge Robot
6a183a98a4
Merge pull request #17925 from giuseppe/v4.4-direct-mapping
[v4.4] libpod: always use direct mapping
2023-03-27 12:27:39 -04:00
OpenShift Merge Robot
439fa3dde6
Merge pull request #17919 from openshift-cherrypick-robot/cherry-pick-17916-to-v4.4
[v4.4] macos pkginstaller: fix regression which caused the installer to fail
2023-03-27 12:24:50 -04:00
Giuseppe Scrivano
223f60e926
libpod: always use direct mapping
always use the direct mapping when writing the mappings for an
idmapped mount.  crun was previously using the reverse mapping, which
is not correct and it is being addressed here:

https://github.com/containers/crun/pull/1147

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
(cherry picked from commit af8d649da7)
2023-03-25 11:16:41 +01:00
Paul Holzinger
c856dd10d7 macos pkginstaller: do not fail when podman-mac-helper fails
Make sure we can install podman even when the podman-mac-helper install
command fails. This used to be the behavior but commit bae07b6ea2 caused
the regression because the binary now returns 1 as exit code on errors.

[NO NEW TESTS NEEDED] I am not sure if we can test the install step in
CI.

Fixes #17910

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-24 17:40:34 +00:00
Paul Holzinger
2f54a3b9aa podman-mac-helper: install: do not error if already installed
Since commit bae07b6ea2 we exit with 1 one errors. This caused problem
for the mac installer which fails because of the error now.
If the helper is already installed do not treat this as hard error and
just log it instead.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-24 17:40:34 +00:00
OpenShift Merge Robot
6172f29f98
Merge pull request #17901 from ashley-cui/rel443
Bump to v4.4.3
2023-03-23 13:14:31 -04:00
Ashley Cui
2c01aa7e38 Bump to v4.4.4-dev
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-03-23 10:17:59 -04:00
Ashley Cui
d2f93d621a
Bump to v4.4.3
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-03-23 10:17:18 -04:00
Ashley Cui
2ae3c4fe97 Release notes for v4.4.3
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-03-23 10:13:51 -04:00
OpenShift Merge Robot
4fc98f639a
Merge pull request #17891 from vrothberg/4.4-backports
4.4 backports
2023-03-22 16:02:30 -04:00
OpenShift Merge Robot
7ad01311e3
Merge pull request #17873 from openshift-cherrypick-robot/cherry-pick-17648-to-v4.4
[v4.4] pkginstaller: bump Qemu to version 7.2.0
2023-03-22 15:59:16 -04:00
Valentin Rothberg
d6ea3983d0 compat: /auth: parse server address correctly
Use `auth.Login` as `podman login` does which parses and normalizes the
input addresses correctly, especially for docker.io.

[NO NEW TESTS NEEDED] as we do not have means to test logging into
docker.io in CI.

Fixes: #17571
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-03-22 17:18:03 +01:00
Valentin Rothberg
0a897f03f8 vendor github.com/containers/common@v0.51.1
Pulls in fixes to add back the SYS_CHROOT to the default set of
capabilities and to pull in fixes for the Docker-compat /auth endpoint
which will be cherry-picked in a subsequent commit.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-03-22 17:17:53 +01:00
OpenShift Merge Robot
85fcf42110
Merge pull request #17871 from openshift-cherrypick-robot/cherry-pick-17661-to-v4.4
[v4.4] podman machine: Adjust Chrony makestep config
2023-03-21 14:05:53 -04:00
Anjan Nath
f7fccc87cf pkginstaller: bump Qemu to version 7.2.0
this updates the Makefile qemu version to make use new qemu released at
https://github.com/containers/podman-machine-qemu/releases/tag/v7.2.0-1

[NO NEW TESTS NEEDED]

Signed-off-by: Anjan Nath <kaludios@gmail.com>
2023-03-21 13:23:41 +00:00
Jordan Christiansen
53212ea0ef podman machine: Adjust Chrony makestep config
This allows Chrony to update the system time when it has drifted far
from NTP time. By default Chrony only makes slight adjustments, but in
the case where a user's laptop lid has been shut for a while and then
the machine is resumed, the VM system time could be hours or days behind
real time, and it may never catch up if Chrony only makes slight
changes.

[NO NEW TESTS NEEDED]

Fixes #11541

Signed-off-by: Jordan Christiansen <xordspar0@gmail.com>
2023-03-21 13:10:02 +00:00
OpenShift Merge Robot
59ce20ddb7
Merge pull request #17862 from vrothberg/v4.4-backport-fix-17777
[v4.4] fix --health-on-failure=restart in transient unit
2023-03-21 07:29:20 -04:00
Valentin Rothberg
06925d5547 [v4.4] fix --health-on-failure=restart in transient unit
As described in #17777, the `restart` on-failure action did not behave
correctly when the health check is being run by a transient systemd
unit.  It ran just fine when being executed outside such a unit, for
instance, manually or, as done in the system tests, in a scripted
fashion.

There were two issue causing the `restart` on-failure action to
misbehave:

1) The transient systemd units used the default `KillMode=cgroup` which
   will nuke all processes in the specific cgroup including the recently
   restarted container/conmon once the main `podman healthcheck run`
   process exits.

2) Podman attempted to remove the transient systemd unit and timer
   during restart.  That is perfectly fine when manually restarting the
   container but not when the restart itself is being executed inside
   such a transient unit.  Ultimately, Podman tried to shoot itself in
   the foot.

Fix both issues by moving the restart logic in the cleanup process.
Instead of restarting the container, the `healthcheck run` will just
stop the container and the cleanup process will restart the container
once it has turned unhealthy.

Backport of commit 9563415430.

Fixes: #17777
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-03-21 09:02:10 +01:00
OpenShift Merge Robot
5106bbffc1
Merge pull request #17819 from Luap99/4.4-backports
[v4.4] Several backports of some of my recent fixes
2023-03-16 15:46:24 -04:00
Paul Holzinger
9c0d2dc2f0
podman logs passthrough driver support --cgroups=split
When run with --cgroups=split mode (e.g. quadlet) we do not use the a
separate cgroup for the container and just run in the unit cgroup.
When we filter logs we thus must match the unit name.
Added a small test to the quadlet test to make sure it will work.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:32:41 +01:00
Paul Holzinger
a0fad9f8ca
journald logs: simplify entry parsing
It makes little sense to create a log line string from the entry just to
parse it again into a LogLine. We have the typed fields so we can
assemble the logLine direclty, this makes things simpler and more
efficient.

Also entries from the passthrough driver do not use the CONTAINER_ID_FULL
field, instead we can just access c.ID() directly.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:32:40 +01:00
Paul Holzinger
54b070ee6a
podman logs: read journald with passthrough
The passthrough driver is designed for use in systemd units. By default
we can expect systemd to log the output on journald unless the unit sets
differen StandardOutput/StandardError settings.

At the moment podman logs just errors out when the passthrough driver is
used. With this change we will read the journald for the unit messages.
The logic is actually very similar to the existing one, we just need to
change the filter. We now filter by SYSTEMD_UNIT wich equals to the
contianer cgroup, this allows us the actually filter on a per contianer
basis even when multiple contianers are started in the same unit, i.e.
via podman-kube@.service.

The only difference a user will see is that journald will merge
stdout/err into one stream so we loose the separation there.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:32:18 +01:00
Paul Holzinger
c5fa9c50f3
journald: remove initializeJournal()
This was added as hack in commit 6b06e9b77c because the journald logs
code was not able to handle an empty journal. But since commit
767947ab88 this is no longer the case, we correctly use the sd_journal
API and know when the journal is empty.

Therefore we no longer need this hack and it should be removed because
it just adds overhead and an empty journal entry for no good reason.

[NO NEW TESTS NEEDED]

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:25:46 +01:00
Paul Holzinger
6b19e1437c
netavark: only use aardvark ip as nameserver
Since commit 06241077cc we use the aardvark per container dns
functionality. This means we should only have the aardvark ip in
resolv.conf otherwise the client resolver could skip aardvark, thus
ignoring the special dns option for this container.

Fixes #17499

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:23:41 +01:00
Paul Holzinger
d737a815a9
compat API: network create return 409 for duplicate
If the name already exists and CheckDuplicate is set we need to return
409, if CheckDuplicate is not set we return the network without error.

Fixes #17585

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:21:56 +01:00
Paul Holzinger
1a3a5594a0
fix "podman logs --since --follow" flake
The test should make sure the logs --follow call will log entries that
are created in the future when --since is used and doe not include the
container start event. However it seems the timing is to tight. I think
it was possible that CI logged the line before the logs call was made,
thus it is missing because --since excluded it.

I cannot reproduce so I am not 100% on this but we can reopen the issue
if it still happens.

Fixes #17616

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:11:11 +01:00
Paul Holzinger
bd65bf2ed1
system service --log-level=trace: support hijack
When the service is running with trace log level it wraps the
`http.ResponseWriter` to log extra information. The problem is that the
new type does not keep all the functions from the embedded type.
Instead we have to implement them ourselves, however only Write() was
implemented. Thus `Hijack()`could not be called on the writer. To
prevent these issues we would implement all the interfaces that the
inner type supports (Header, WriteHeader, Flush, Hijack).

Fixes #17749

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:10:30 +01:00
Paul Holzinger
8ab00424bc
podman-mac-helper: exit 1 on error
We should return a proper exit code to signal the failure.

[NO NEW TESTS NEEDED] We do have any tests on macOS.

Fixes #17785

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-03-16 15:08:19 +01:00
OpenShift Merge Robot
fc729b2e23
Merge pull request #17809 from lsm5/v4.4-http2-080
[v4.4] bump golang.org/x/net to v0.8.0
2023-03-16 09:24:57 -04:00
Lokesh Mandvekar
badbd8a34c
bump golang.org/x/net to v0.8.0
Resolves: CVE-2022-41723

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-03-16 15:42:52 +05:30
Daniel J Walsh
a5d4551cff
Merge pull request #17689 from openshift-cherrypick-robot/cherry-pick-17686-to-v4.4
[v4.4] Fix package restore of shadow-utils on Windows
2023-03-04 11:29:27 -05:00
Jason T. Greene
36ab43f773 Fix package restore
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2023-03-03 18:46:08 +00:00
OpenShift Merge Robot
73ce3c61c1
Merge pull request #17641 from dcermak/quadlet-dont-set-runtime-backport
[v4.4] Quadlet - use the default runtime
2023-02-27 14:48:13 +01:00
Ygal Blum
df0fe4fcc7
Quadlet - use the default runtime
Do not set the runtime when processing a .container file
Let Podman choose the runtime based on its configuration

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
Signed-off-by: Dan Čermák <dcermak@suse.com>
(cherry picked from commit 0d75854c52)
2023-02-27 12:04:48 +01:00
OpenShift Merge Robot
a302d386a1
Merge pull request #17618 from ashley-cui/442
Bump to v4.4.2
2023-02-23 20:14:57 +01:00
Ashley Cui
594d488b82 Bump to v4.4.3-dev
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-02-23 10:59:50 -05:00
Ashley Cui
74afe26887
Bump to v4.4.2
Signed-off-by: Ashley Cui <acui@redhat.com>
2023-02-23 10:59:21 -05:00
Ashley Cui
87a1c2701a Release notes for v4.4.2
And an adjustment to release notes for v4.4.1

Signed-off-by: Ashley Cui <acui@redhat.com>
2023-02-23 10:58:56 -05:00
OpenShift Merge Robot
266ce9a3a1
Merge pull request #17557 from openshift-cherrypick-robot/cherry-pick-17554-to-v4.4
[v4.4] [CI:BUILD] Revert "CI: Temporarily disable all AWS EC2-based tasks"
2023-02-18 13:54:00 +01:00
Chris Evich
3abff420a9 Revert "CI: Temporarily disable all AWS EC2-based tasks"
This reverts commit 7f8bc6f510.

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-02-17 18:42:01 +00:00
OpenShift Merge Robot
2d68f21a13
Merge pull request #17553 from openshift-cherrypick-robot/cherry-pick-17548-to-v4.4
[v4.4] kube play: only enforce passthrough in Quadlet
2023-02-17 17:47:52 +01:00
OpenShift Merge Robot
9168027b08
Merge pull request #17552 from openshift-cherrypick-robot/cherry-pick-17544-to-v4.4
[v4.4] Emergency fix for man pages: check for broken includes
2023-02-17 16:53:15 +01:00
OpenShift Merge Robot
f60a6cd0d2
Merge pull request #17549 from openshift-cherrypick-robot/cherry-pick-17525-to-v4.4
[v4.4] quadlet system tests: add useful defaults, logging
2023-02-17 16:50:37 +01:00
OpenShift Merge Robot
f17495e141
Merge pull request #17532 from mheon/backport_17528_44
Backport #17528 to v4.4
2023-02-17 16:47:40 +01:00
Valentin Rothberg
8322cab918 kube play: only enforce passthrough in Quadlet
Only enforce the passthrough log driver for Quadlet. Commit 68fbebf
introduced a regression on the `podman-kube@` template as `podman logs`
stopped working and settings from containers.conf were ignored.

Fixes: #17482
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-02-17 15:01:35 +00:00
Ed Santiago
d69512b98a Emergency fix for man pages: check for broken includes
Somehow the options/secret.md file generated corrupt md which
then generated corrupt .man files. Fix, and add a Makefile
check to prevent this from happening again.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-17 14:38:19 +00:00
OpenShift Merge Robot
429a00deed
Merge pull request #17551 from openshift-cherrypick-robot/cherry-pick-17541-to-v4.4
[v4.4] CI: Temporarily disable all AWS EC2-based tasks
2023-02-17 15:02:36 +01:00
Chris Evich
9606d7f992 CI: Temporarily disable all AWS EC2-based tasks
An ongoing issue with uploading artifacts is hindering development
progress.  Temporarily disable all aflicted tasks until the problem is
resolved.  Typical error message:

```
Uploading 1 artifacts for
Failed to upload artifacts: Put
...cut...
tls: server selected unsupported protocol version 303
Re-trying to artifacts upload...
```

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-02-17 13:56:00 +00:00
Ed Santiago
ab7a47840f quadlet system tests: add useful defaults, logging
Tests constantly fail with zero indication of why. Fix that.
 - add correct default for $QUADLET path
 - add check to make sure it exists
 - log quadlet commands and their output

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-02-17 11:18:30 +00:00