Commit Graph

4170 Commits

Author SHA1 Message Date
Matt Heon
75d68ea174 Merge pull request #28414 from Honny1/fix-quadlet-lookup-strip
Fix Quadlet `Lookup()` stripping unmatched quotes
2026-03-31 11:14:47 -04:00
Jan Rodák
cf6404f387 Fix Quadlet Lookup() stripping unmatched quotes
Fixes: https://github.com/containers/podman/issues/28409

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-31 10:27:39 +02:00
Matt Heon
e3920188cc Merge pull request #28408 from jdoss/fix/shell-driver-opts-cross-contamination
Fix shell driver DriverOpts cross-contamination in secret creation
2026-03-30 11:20:11 -04:00
Joe Doss
8b905613b5 Add e2e test for shell driver DriverOpts cross-contamination fix
Verify that creating a secret with driver=shell and no --driver-opts
does not inherit the file driver's default path option. Before the fix,
this produced "invalid shell driver option"; after, it correctly fails
with "missing config value" for unconfigured shell commands.

Signed-off-by: Joe Doss <joe@solidadmin.com>
2026-03-30 08:36:00 -05:00
Devesh B
1d4465abf7 test(artifact): add e2e test for untagged artifact default tag
Verify that artifacts pushed without an explicit tag display "latest"
in the TAG column of `podman artifact ls`.

Signed-off-by: Devesh B <98201065+DeveshB-1@users.noreply.github.com>
2026-03-30 00:16:08 +05:30
Paul Holzinger
bb5f759ba8 test/e2e: fix podman pull and run on split imagestore test
We no longer generate a warning for an empty driver in storage.conf so
remove that.

Also update the test to use CONTAINERS_STORAGE_CONF_OVERRIDE instead to
just add a single setting there.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2026-03-19 21:49:20 +01:00
Paul Holzinger
0147339e8e Merge pull request #28202 from lsm5/podman6-no-cni-vendor
Podman6: Vendor update w/o CNI + additional cleanups
2026-03-19 21:44:01 +01:00
Paul Holzinger
d2e7e8192e Merge pull request #28235 from Honny1/volume-prune-docker
`podman volume prune`: match Docker defaults, add `--all` flag
2026-03-19 17:53:18 +01:00
Lokesh Mandvekar
61cb417c26 Remove CNI references from comments
Update comments that reference CNI as a network backend since it
has been removed.

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2026-03-19 20:26:21 +05:30
Lokesh Mandvekar
8d1f636e40 vendor update without CNI in buildah and container-libs
rootlessport: clarify RootlessCNI comment

Update the comment for the RootlessCNI conditional to clarify that
the flag is for rootless bridge networking, not CNI specifically.
The bool is set when netStatus != nil in slirp4netns and will be
removed when slirp4netns and rootlessport are fully dropped.

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2026-03-19 20:26:21 +05:30
Tom Sweeney
bb9d188d4a Merge pull request #28236 from Honny1/fix-unless-stopped
Fix `unless-stopped` containers not restarting after `podman-restart-service` stop them
2026-03-19 10:45:28 -04:00
Jan Rodák
a63910314f Refactor volume_prune tests to use PodmanExitCleanly
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-19 13:40:47 +01:00
Jan Rodák
339acf880c volume prune: match Docker default and add --all
Fixes: https://github.com/containers/podman/issues/24597
Fixes: https://issues.redhat.com/browse/RUN-4404

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-19 13:40:45 +01:00
Jan Rodák
7326b862e3 Fix unless-stopped containers not restarting after podman-restart.service stop them
When `podman-restart.service` stops containers, it marks them as "stopped by
user" which breaks the `unless-stopped` restart policy. Add hidden
`--not-stopped-by-user` flag to prevent this, allowing `unless-stopped`
containers to restart on next boot.

Fixes: https://github.com/containers/podman/issues/28152
Fixes: https://issues.redhat.com/browse/RUN-4357

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-16 13:51:17 +01:00
Jan Rodák
1ccded76ce Use InspectNetwork helper in e2e tests
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-16 13:47:01 +01:00
Jan Rodák
6acfd58026 Add multi-IP container support
Add tests for multiple static IPs per container across single and multi-subnet networks.
Document --network option for comma-separated IPs and subnet-based IP ordering.

Fixes: https://issues.redhat.com/browse/RHEL-98277

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-03-16 13:47:01 +01:00
Jan Rodák
e3754862d1 Merge pull request #28265 from kyounghunJang/main
feat: print client info from `podman version` when the server is not available
2026-03-16 11:35:16 +01:00
Tom Sweeney
8b0f9eb8a4 Merge pull request #28281 from ricardobranco777/arm64e2e
tests/e2e: Do not try to list /proc/acpi on non-amd64
2026-03-13 13:25:49 -04:00
KyounghoonJang
c7921b0049 feat: print client info from podman version when the server is unavailable
In remote mode, `podman version` currently returns a connection error before
printing any version information if it cannot connect to the service.

Introduce a reusable `PrintVersion` helper and invoke it at the root level
when a `ConnectionError` is encountered. This ensures that client information
is still shown even when the server cannot be reached.

Fixes: #28222
Signed-off-by: KyounghoonJang <matkimchi_@naver.com>
2026-03-13 19:09:54 +09:00
umut-polat
926f562bd5 quadlet: allow empty Entrypoint to clear image default
Setting Entrypoint= (empty value) in a quadlet .container file should
produce --entrypoint "" in the generated podman command, which clears
the image's default entrypoint. Previously this was silently ignored
because lookupAndAddString skips empty values.

Move the Entrypoint key out of the generic stringKeys map and handle
it separately so that an empty value is passed through.

Closes #28213

Signed-off-by: umut-polat <52835619+umut-polat@users.noreply.github.com>
2026-03-13 08:14:57 +00:00
Ricardo Branco
67ccf4940c tests/e2e: Do not try to list /proc/acpi on non-amd64
Signed-off-by: Ricardo Branco <rbranco@suse.de>
2026-03-12 21:31:11 +01:00
Paul Holzinger
1f3c344312 run modernize -fix ./...
modernize seems to be smarter now so it found some more things that are
not even go 1.25 related.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2026-03-12 17:22:01 +01:00
Ricardo Branco
cd2f122fb4 test/e2e: Skip some tests on non-amd64 architectures
Signed-off-by: Ricardo Branco <rbranco@suse.de>
2026-03-12 15:18:04 +01:00
Ricardo Branco
a5dbe484d3 test/e2e: Introduce SkipIfNotAMD64 helper
Signed-off-by: Ricardo Branco <rbranco@suse.de>
2026-03-12 14:53:05 +01:00
Ricardo Branco
e5f61281ff test/e2e: skip LINUX32 personality check on non-amd64 architectures
Signed-off-by: Ricardo Branco <rbranco@suse.de>
2026-03-12 14:53:05 +01:00
Ricardo Branco
a4d0fd8853 test/e2e: Add linkat to seccomp profile
Some architectures (i.e., arm64) do not implement the link(2) system
call and ln(1) uses linkat(2) instead.

Use the names array to block both syscalls so the tests works on all
architectures.

Signed-off-by: Ricardo Branco <rbranco@suse.de>
2026-03-12 14:53:05 +01:00
Paul Holzinger
5adac65c0a Merge pull request #28208 from mtrmac/tls-behavior-basics
Add --tls-details for (pull, push, run, login, logout)
2026-03-06 16:33:38 +01:00
Povilas Kanapickas
636eb1a401 libpod: Implement --log-opt label=LABEL=Value
This allows things like compose project names to be associated with log
messages and later used in log processing and analysis.

Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
2026-03-06 10:59:31 +02:00
Miloslav Trmač
7fd3be8288 Add --tls-details support for (podman login) and (podman logout)
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2026-03-06 00:33:14 +01:00
Miloslav Trmač
13e1d5af4b PARTIALLY TESTED: Add --tls-details, use it to affect libimage and the like
For remote operation, start the remote service with --tls-details:
using --tls-details on the client side will only affect client's
connection.

This should eventually include many more tests - track down all current
uses of libpod.Runtime.{SystemContext,imageContext,LibimageRuntime}.
That will come later

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2026-03-05 23:13:17 +01:00
Povilas Kanapickas
9872cbd756 libpod: Validate that log tag requires journald driver
Currently validation that log tag requires journald driver is done in several
places and emits only warning. Making it an error and moving to
`(c *Container) validate()` is a more correct approach.

Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
2026-03-04 14:48:46 +02:00
Paul Holzinger
8aad8d72e0 Merge pull request #28140 from ozgur-as/fix-clone-secret-env
Fix container clone with secret type=env
2026-03-04 13:04:11 +01:00
Paul Holzinger
d2a0cef55c Merge pull request #28188 from mtrmac/sprintf-split
Don’t use `strings.Split(fmt.Sprintf("--a b …", …), " ")`
2026-03-04 12:01:12 +01:00
Miloslav Trmač
acdaa5372e Don't use strings.Split(fmt.Sprintf("--a b ...", ...), " ")
When we have the _precise_ knowledge of where the parameter boundaries
are, and an API that allows us to express that, just _do that_ instead
of completely unnecessarily worrying about spaces in parameter values.

Also, this allows us to format the code to make the option and value
correspondence much easier to see.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2026-03-04 00:14:37 +01:00
Miloslav Trmač
b1837f8824 Rename the fedoraMinimal constant to FEDORA_MINIMAL
... following the existing style.

Should not change behavior.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2026-03-03 21:34:14 +01:00
Miloslav Trmač
c42350a5a2 Fix compilation of tests on arm64
fedoraMinimal is referenced in non-_test config_arm64.go
and config_ppc64le.go.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>
2026-03-03 21:30:05 +01:00
Jan Rodák
a11f22292e Merge pull request #28161 from ygalblum/quadlet-volume-mount-options
Quadlet Volume - allow setting mount option without a device
2026-03-02 16:37:35 +01:00
Ygal Blum
6c41f55aa7 Quadlet Volume - allow setting mount option without a device
Fixes: #28132

Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2026-02-26 12:27:23 -05:00
Ygal Blum
64ec31ac00 Add nocreate option for named volumes
Add a per-volume 'nocreate' option that prevents automatic creation of
named volumes when they don't exist. When specified, Podman will fail
if the volume is not found instead of creating it automatically.

Usage: -v myvolume:/data:nocreate
       --mount type=volume,src=myvolume,dst=/data,nocreate

See: #27862
Signed-off-by: Ygal Blum <ygal.blum@gmail.com>
2026-02-26 11:14:32 -05:00
Ozgur As
03d9de1528 Fix container clone with secret type=env
ConfigToSpec() serializes the container config to JSON and deserializes
it into a SpecGenerator. Both structs use the JSON tag "secret_env" but
with incompatible types: the container config uses map[string]*secrets.Secret
(complex objects) while the specgen uses map[string]string (env var name
to secret name). This causes an unmarshal error when cloning containers
that use --secret with type=env.

Fix this by saving and clearing EnvSecrets before JSON marshal (same
pattern as existing tmpSystemd/tmpMounts), then converting the secret
objects to name strings and assigning them to the specgen afterward.

Also fix FillOutSpecGen to not overwrite env secrets populated by
ConfigToSpec when no new secrets are provided on the command line.

Fixes: #28130
Signed-off-by: Ozgur As <ozgur@live.com>
2026-02-25 19:53:36 +03:00
Jan Rodák
c581a93da5 Merge pull request #28095 from MayorFaj/fix/28031-publish-option
fix: add validation for --publish flag in container restore
2026-02-18 10:19:06 +01:00
Jan Rodák
33e8abd637 Respect user-specified Restart= policy in pod units
Fixes: https://github.com/containers/podman/issues/28081

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2026-02-16 22:12:18 +01:00
MayorFaj
1aefd06760 test: remove redundant test for restoring with --publish without --import
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2026-02-16 20:13:45 +00:00
MayorFaj
5a1a54424c fix: enforce --publish option usage with --import in podman restore
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2026-02-15 09:38:58 +00:00
Šimon Brauner
9727a43f5a Added setting UID and GID for volumes in quadlet
Related: https://issues.redhat.com/browse/RHEL-145863

Signed-off-by: Šimon Brauner <sbrauner@redhat.com>
2026-02-11 18:16:30 +01:00
Patrick Wicki
3856389fc9 podman-healthcheck-run: add --ignore-result flag
This is useful for triggering the execution of a healthcheck
without caring about it's result as long as no fatal error occured.

Signed-off-by: Patrick Wicki <patrick.wicki@siemens.com>
2026-02-09 19:52:29 +01:00
Matt Heon
d220d58f08 Merge pull request #27993 from danishprakash/podman-buildah-vendor
vendor: update c/buildah to latest main
2026-02-04 16:02:39 -05:00
Mario Loriedo
6e053689d5 Merge pull request #27795 from MayorFaj/fix-env-envfrom-precedence-27287
fix: ensure environment variable precedence between env and envFrom
2026-02-03 11:31:59 +01:00
Danish Prakash
827ba37b3e build: handle --iidfile-raw and --metadata-file flags
* docs: man page additions
* test/e2e: add tests for `--iidfile-raw` and `--metadata-file`
* test/buildah-bud: update buildah-bud test patch for buildah v1.42.1

Signed-off-by: Danish Prakash <contact@danishpraka.sh>
2026-02-03 09:18:29 +05:30
Lokesh Mandvekar
73ef7cfcdc Remove CNI backend from CLI options and completions
Remove user-facing CLI options for CNI network backend:

CLI flags:
- Keep --network-backend global flag as hidden and deprecated for
  backward compatibility with cleanup commands from 5.x containers
- Map flag to a throwaway variable (value is ignored)
- Remove shell completion for network backend values

Shell completions:
- Remove AutocompleteNetworkBackend() function
- Remove references to CNI and Netavark type constants

Backward compatibility:
- Remove --rootless-cni flag alias for podman unshare
- Remove SetNormalizeFunc that mapped rootless-cni to rootless-netns
- Update --rootless-netns flag description to mention only netavark

The --network-backend flag remains as a hidden deprecated flag to
prevent failures when upgrading from 5.x where containers may have
cleanup commands that include this flag. The flag is accepted but
ignored. Users can no longer specify CNI as a network backend option.
The --rootless-cni alias is removed; users must use --rootless-netns.

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2026-01-27 16:32:38 +05:30