1
0
mirror of https://github.com/containers/podman.git synced 2026-02-05 15:45:08 +01:00
Commit Graph

26577 Commits

Author SHA1 Message Date
openshift-merge-bot[bot]
f8e0b70063 Merge pull request #27727 from cfergeau/openatinroot
kube play: Fix fd leak when handling symlinks
2025-12-09 18:28:37 +00:00
Jhon Honce
9fe88a5539 Finish review comments
* Provide hints to AI agents to differentiate between system and
  integration tests

Signed-off-by: Jhon Honce <jhonce@redhat.com>
2025-12-09 09:41:06 -07:00
Christophe Fergeau
84a2902d32 kube play: Fix fd leak when handling symlinks
The `*os.File` returned by `pathrs.OpenatInRoot` needs to
be closed before returning from `openSymlinkPath`

Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
2025-12-09 16:28:16 +01:00
openshift-merge-bot[bot]
f66f7c8a5b Merge pull request #27650 from lstocchi/i27614
Prevent non hyper-v admin users to execute machine commands
2025-12-09 12:17:38 +00:00
Jhon Honce
f095336456 Update to resolve most review comments
Signed-off-by: Jhon Honce <jhonce@redhat.com>
2025-12-08 18:31:33 -07:00
openshift-merge-bot[bot]
ed132b7a72 Merge pull request #27709 from baude/removedarwinamd64
Remove Intel MacOS support
2025-12-09 01:20:42 +00:00
Jhon Honce
8d7e200f88 Initial draft of AGENTS.md
* Add support for https://agents.md/

[NO TESTS NEEDED]

Signed-off-by: Jhon Honce <jhonce@redhat.com>
See: [AGENTS.md](https://agents.md/)
2025-12-08 17:54:50 -07:00
Brent Baude
f87cefc262 Remove Intel MacOS support
This PR removes support for Intel Apple Macs. The removal includes
impacts to code, tests, Makefile, builds, release builds, and so forth.

Fixes Jira: RUN-3621

Signed-off-by: Brent Baude <bbaude@redhat.com>
2025-12-07 07:03:06 -06:00
MayorFaj
e28d1e57fa fix(logs): enhance timestamp format to include timezone in logs
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2025-12-06 13:10:28 +00:00
MayorFaj
2bbf26de0c fix(logs): add tests for nanosecond precision in log timestamps
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2025-12-06 12:17:39 +00:00
MayorFaj
4043a4bb0c docs: Update filter options and add podman ps documentation
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2025-12-06 10:47:13 +00:00
MayorFaj
60a5a476d5 fix(logs): improve timestamp precision in container logs
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2025-12-05 16:28:29 +00:00
openshift-merge-bot[bot]
8ce77d6e6b Merge pull request #27687 from mheon/deterministic_pod_inspect
Deterministically order pod inspect fields
2025-12-05 14:07:55 +00:00
MayorFaj
3b080ce918 docs: Deduplicate --filter descriptions
Signed-off-by: MayorFaj <mayorfaj@gmail.com>
2025-12-05 00:36:53 +00:00
Matt Heon
a8ecb80ac0 Deterministically order pod inspect fields
There are two fields I'm worried about: shared namespaces and pod
containers. Both are generated via loops over maps and are thus
non-deterministic in ordering. Throw a sort on each to fix the
order so we can actually diff `podman pod inspect` output.

Signed-off-by: Matt Heon <mheon@redhat.com>
2025-12-04 15:25:11 -05:00
openshift-merge-bot[bot]
244aa643c7 Merge pull request #27672 from Luap99/workdir
libpod: fix workdir MkdirAll() all check
2025-12-04 15:52:35 +00:00
openshift-merge-bot[bot]
f5ea6f16d2 Merge pull request #27645 from containers/renovate/github.com-shirou-gopsutil-v4-4.x
Update module github.com/shirou/gopsutil/v4 to v4.25.11
2025-12-04 15:35:39 +00:00
openshift-merge-bot[bot]
5508d873c1 Merge pull request #27619 from Honny1/fix-unless-stopped-reboot
Fix `unless-stopped` restart policy to match Docker behavior
2025-12-04 15:04:10 +00:00
Paul Holzinger
d18e44e9ab libpod: simplify resolveWorkDir()
The code checks for isPathOnVolume and isPathOnMount so we can just use
the SecureJoin here directly to check for path existance.

Then instead of walking symlinks and trying to guess if they are on a
mount just assume if it is a link (path is different from the normal
joined one) then don't error out early and let the OCI runtime deal with
it. The runtime does produce a less readable error but it still fails
and we have much less fragile code.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2025-12-04 15:25:49 +01:00
Paul Holzinger
7b1be7f177 libpod: fix workdir MkdirAll() all check
MkdirAll can fail with EEXIST when the path is a symlink and the target
doesn't exist. As such we should ignore the error.

Note there is something fundemantal wrong here with the path access as
it is following the symlink to the host, however it is only for a
stat() so it is not an security issue here.

Fixes: 637c264e2e ("fix issues found by nilness")

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2025-12-04 15:25:30 +01:00
openshift-merge-bot[bot]
0bd2b4b358 Merge pull request #27602 from ZuhairM7/fix-remote-build-secrets
bindings: fix handling of env secrets in remote builds
2025-12-04 13:15:24 +00:00
openshift-merge-bot[bot]
32be5c3f42 Merge pull request #27664 from givensuman/T-27632-list-json-bug
Add Repository and Tag fields to image list --format JSON output
2025-12-04 13:12:38 +00:00
givensuman
2461ccd621 Add Repository and Tag fields to image list --format JSON output
Adds two fields to the output of `podman image list --format json`,
"Repository" and "Tag." Consequently makes the existing embedded field
"RepoTag" redundant, and in current implementation is always `nil`. Adds
`json:",omitempty"` to improve program output.

Fixes: #27632

Signed-off-by: givensuman <givensuman@duck.com>
2025-12-03 17:53:26 -05:00
openshift-merge-bot[bot]
5134dd3bee Merge pull request #27663 from HastD/zizmor-workflow
ci: add Zizmor workflow
2025-12-03 15:29:57 +00:00
openshift-merge-bot[bot]
963aabb54b Merge pull request #27551 from lsm5/cgv1-removal-vendor
CGgroups v1 cleanup: Round 2 w/ container-libs vendoring
2025-12-03 14:00:04 +00:00
Daniel Hast
1dbb897733 ci: add Zizmor workflow
Zizmor (https://docs.zizmor.sh/) is a static analysis tool for GitHub
Actions. Most of the issues identified by Zizmor were fixed in #27642.
This Zizmor action integrates with GitHub Advanced Security and scans
workflows for potential security issues, which should help ensure that
such issues aren't reintroduced in the future.

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-02 18:12:15 -05:00
ZuhairM7
fdbb696731 bindings: fix handling of env secrets in remote builds
Previously, using --secret=id=foo,env=BAR in remote mode would fail because the client sent the env var name to the server, which tried to resolve it locally. This patch modifies the client to resolve the environment variable locally, write it to a temp file, and send it as a file-based secret.

Fixes #27494

Signed-off-by: ZuhairM7 <ZuhairM7>
Signed-off-by: ZuhairM7 <zuhairmerali@gmail.com>
2025-12-02 16:21:49 -06:00
Lokesh Mandvekar
b78f1cf986 vendor: update container-libs to df55d6c661e8 for cgv1 removal
Also simplifies cgroups.AvailableControllers

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-12-02 15:38:30 -05:00
openshift-merge-bot[bot]
4eaff6fe22 Merge pull request #27662 from baude/addperltomakevalidatepr
Add perl to make validatepr
2025-12-02 19:27:27 +00:00
Brent Baude
1bddd38e0a Add perl to make validatepr
Users reported that our container image for make validatepr needs perl
base installed.

Signed-off-by: Brent Baude <bbaude@redhat.com>
2025-12-02 12:47:34 -06:00
lstocchi
d150051d7a add windows platform tests
Signed-off-by: lstocchi <lstocchi@redhat.com>
2025-12-02 16:28:20 +01:00
lstocchi
85fe4de1ee fix failing windows platform tests
fixes broken windows tests and enables them to be run on
windows CI

Signed-off-by: lstocchi <lstocchi@redhat.com>
2025-12-02 16:19:50 +01:00
lstocchi
1bd51314ff prevent non hyper-v admin users to execute machine commands
Update GetAll() and GetByVMType() to add a check to prevent non hyper-v admin users to
interact with hyperv machines.
Users can work with hyperv machines only with elevated rights or if
members of the hyperv administrators group

Signed-off-by: lstocchi <lstocchi@redhat.com>
2025-12-02 16:19:31 +01:00
Jan Rodák
4d3c6311a5 Fix unless-stopped restart policy to match Docker behavior
- Update documentation: Differentiate `unless-stopped` from `always` - containers stopped by the user before a reboot will not restart.
- Add `should-start-on-boot` filter: Identify containers that require a restart after a system reboot.
- Update command documentation: Add `restart-policy` and `label!` filters to the documentation for container commands (rm, ps, start, stop, pause, unpause, restart).
- Add `restart-policy` and `shoud-start-on-boot` to completions.
- Update service: Update `podman-restart.service` to use the `needs-restart=true` filter.
- Preserve state: Preserve the `StoppedByUser` state across reboots.
- Update API: Add a `ShouldStartOnBoot()` method to the Container API.
- Update documentation: Add descriptions for the `should-start-on-boot` filter.

Fixes: https://issues.redhat.com/browse/RHEL-129405
Fixes: https://github.com/containers/podman/issues/20418

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2025-12-02 15:40:46 +01:00
openshift-merge-bot[bot]
9a811bf5ac Merge pull request #27642 from HastD/zizmor-issues
ci: fix Zizmor-identified issues in workflows
2025-12-02 14:17:46 +00:00
Daniel Hast
67c050bb8e ci: use env vars to avoid template expansion in code contexts
Template expansions are not aware of shell script syntax, and therefore
can potentially result in code injection vulnerabilities when used in
code contexts: https://docs.zizmor.sh/audits/#template-injection

To avoid this, instead use environment variables to safely store the
values of the template expansions.

Also (in the process of doing the above) added double-quotes around a
some instances of variable expansions in shell scripts, which is
necessary to avoid unintended shell splitting and globbing. (I didn't
see any instances where this was actually likely to result in erroneous
behavior, but it's good practice and makes shell scripts more robust.)

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:43:09 -05:00
Daniel Hast
3f4af378f4 ci: use --sandbox for dynamically generated sed scripts
sed scripts are capable of doing file I/O and executing arbitrary
commands. The `--sandbox` option prevents this by rejecting sed commands
with such capabilities; it's good practice to use this whenever the sed
script is dynamically generated (e.g. if it involves a variable
expansion).

Also fixed an error in one sed script where `.*` had been placed outside
of the quoted string (and would therefore be subject to shell globbing),
presumably due to single-quotes having been changed to double-quotes at
some point in the past.

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:43:05 -05:00
Daniel Hast
b9736e8d11 ci: pass secrets explicitly to reusable workflow
Using `secrets: inherit` forwards all secrets to the workflow and makes
it harder to determine which secrets the workflow was actually executed
with. See: https://docs.zizmor.sh/audits/#secrets-inherit

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:43:01 -05:00
Daniel Hast
64ddbfea12 ci: disable caching for actions/setup-go
This mitigates a potential cache-poisoning attack. For details, see:
https://docs.zizmor.sh/audits/#cache-poisoning

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:42:54 -05:00
Daniel Hast
0752c5327e ci: specify persist-credentials for actions/checkout
Explicitly set `persist-credentials: true` for uses of
`actions/checkout` where it's needed (when the job does git operations
using the stored credentials) and `persist-credentials: false` where the
stored credentials are not later used.

This reduces the risk of cached credentials accidentally being leaked
via artifacts.

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:42:49 -05:00
Daniel Hast
30495081b7 ci: specify workflow permissions per job
Also remove some unnecessary permissions:

* The notification job in release-artifacts.yml only needs to read repo
  contents, not write contents and actions.
* All jobs in release.yml except "Create release" and "Update podman.io"
  only need to read repo contents. "Update podman.io" only needs to
  write repo contents and pull requests.
* Likewise, permissions for update-podmanio.yml can be restricted to
  only writing repo contents and pull requests.

Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:42:39 -05:00
Daniel Hast
248d8f64a6 ci: pin 3rd-party action dependencies by commit hashes
Signed-off-by: Daniel Hast <hast.daniel@protonmail.com>
2025-12-01 08:41:55 -05:00
renovate[bot]
5fa0327246 Update module github.com/shirou/gopsutil/v4 to v4.25.11
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-12-01 13:25:37 +00:00
openshift-merge-bot[bot]
3681055601 Merge pull request #27644 from containers/renovate/github.com-sirupsen-logrus-digest
Update github.com/sirupsen/logrus digest to b61f268
2025-12-01 13:23:46 +00:00
renovate[bot]
b56ddd03a6 Update github.com/sirupsen/logrus digest to b61f268
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-12-01 10:14:35 +00:00
openshift-merge-bot[bot]
66bad3d2df Merge pull request #27638 from containers/renovate/common-image-and-storage-deps
Update common, image, and storage deps to 94e31d2
2025-12-01 10:12:26 +00:00
renovate[bot]
89ddae8b12 Update common, image, and storage deps to 94e31d2
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-30 01:50:27 +00:00
openshift-merge-bot[bot]
89844e51d5 Merge pull request #27608 from kyounghunJang/feature/Add-DefaultNetwork
feat(info): expose default network name
2025-11-28 11:20:27 +00:00
openshift-merge-bot[bot]
8bc5591fec Merge pull request #27621 from travier/main-docs-fixup
docs/podman.1: Fix leftover rootless mention
2025-11-28 10:57:26 +00:00
Kyounghoon Jang
2e26deea33 Add test for exposing default network name in podman info
Fixes #27580

Signed-off-by: Kyounghoon Jang <matkimchi_@naver.com>
2025-11-28 09:49:02 +09:00