We only need qemu-system-[x86|aarch64]-core based on the architecture
along with qemu-img. So, there's no need to pull in all of qemu.
The qemu-system-[x86|aarch64]-core packages are not present on CentOS
Stream and RHEL, so we use qemu-kvm there instead.
Ref: https://github.com/containers/podman/pull/24369/files#r1883658262
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
BuildOrigin is a field that can be set at build time by packagers. This helps us trace how and where the binary was built and installed from, allowing us to see if the issue is due to a specfic installation or a general podman bug. This field shows up in podman version and in podman info when populated. Note that podman info has a new field, Client, that only appears when running podman info using the remote client.
Automatically set the BuildOrigin field when building the macOS pkginstaller to pkginstaller.
Usage: make podman-remote BUILD_ORIGIN="mypackaging"
Signed-off-by: Ashley Cui <acui@redhat.com>
`argv[0]`, ie: the full buffer allocated by `get_cmd_line_args`,
was going to be freed only if `can_use_shortcut()` was called.
Instead, let `init()` always manage `argv0` lifecycle.
Signed-off-by: Federico Di Pierro <nierro92@gmail.com>
As issue #25112 points out, it was possible to start a machine on one of the darwin providers and then switch providers and start another one with a different name. This PR firstly prevents that use which is a forbidden use case.
Secondarily, performed some minor cleanup on the error messages being used so that the error would be specific to this condition.
This bug fix is for darwin only. In the case of Windows, we probably need to answer the question I raised in #24067 first, which is whether we want to stop allowing WSL to run multiple machines.
Fixes#25112
Signed-off-by: Brent Baude <bbaude@redhat.com>
A function in the reset code does not return an error. Simply removing the error variable and check for the condition (which was always false or nil)
Signed-off-by: Brent Baude <bbaude@redhat.com>
The Kind() exported function is unused in our code; moreover, the function cannot be accurate because in the case of darwin, applehv and libkrun use the same config in the struct and therefore, we cannot identify the provider via that method.
Signed-off-by: Brent Baude <bbaude@redhat.com>
The behavior of function `path/filepath.EvalSymlinks()` has
changed in Go v1.23:
- https://go-review.googlesource.com/c/go/+/565136
- https://go.dev/doc/go1.23#minor_library_changes
- https://tip.golang.org/doc/godebug
As a consequences, starting with Podman 5.3.0, when installing
on Windows (WSL) using scoop, Podman fails to start because it
fails to find helper binaries. Scoop copies Podman binaries in
a folder of type Junction and `EvalSymlinks` returns an error.
The problem is described in #24557.
To address this problem we are checking if a path is a `Symlink`
before calling `EvalSymlinks` and, if it's not (hardlinks, mount
points or canonical files), we are calling `path/filepath.Clean`
for consistency. In fact `path/filepath.EvalSymlinks`, after
evaluating a symlink target, calls `Clean` too.
Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
They are new and failing on remote, needs to be looked at (#25138)
For now skip them so we can have a proper buildah vendored for rc2.
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
If no containers need to be restarted, podman-restart prints "Error: you must provide at least one name or id" then fails.
Update the service file to handle start and stop symmetrically.
See discussion in https://github.com/containers/podman/pull/25131
Signed-off-by: Andrew Sayers <andrew-github.com@pileofstuff.org>
Added a condition in the Windows WiX bundle that
prevents upgrades from v5.3.1 and recommend the
user to upgrade to v5.3.2 first.
That's needed because version 5.3.1 of the installer
had a bug that got patched in v5.3.2 only.
c.f. https://github.com/containers/podman/issues/24735
Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
The `podman system prune` command is able to remove build containers that were created during the build, but were not removed because the build terminated unexpectedly.
By default, build containers are not removed to prevent interference with builds in progress. Use the **--build** flag when running the command to remove build containers as well.
Fixes: https://issues.redhat.com/browse/RHEL-62009
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
The test `podman selinux: check unsupported relabel` has been failing
recently on Fedora rawhide.
This is due to a regression in the `ls` command itself. Workaround for
now is to switch to `getfattr -n security.selinux ...`.
Ref: https://github.com/containers/podman/issues/25132#issuecomment-2615744915Fixes: #25132
Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
This is a generalization of PodmanExitCleanly, scalable
to an arbitrary number of possible options.
Should not change behavior.
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
It seems this utility is not all that generally useful,
so eliminate it from the global namespace and use
PodmanWithOptions directly.
Should not change behavior.
Signed-off-by: Miloslav Trmač <mitr@redhat.com>