Skip to content

Conversation

@Honny1
Copy link
Member

@Honny1 Honny1 commented Dec 18, 2025

This PR adds a new local artifact add API endpoint and enforces absolute path requirements for local file operations.

Fixes: https://issues.redhat.com/browse/RUN-3385
Fixes: #26321

Benchmark

  • Command: podman artifact add quay.io/myartifact/benchmark:latest ./artifacts/random-file
  • Artifacts Dir content:
$ du -a -h | sort -hr
5G	.
5.0G ./random-file

Benchmark Results:

Mac OS

  • Number of runs: 10
  • Machine:
    • Chip: Apple M3 Pro
    • RAM: 36 GB
    • SSD: 1 TB Apple SSD
  • Podman machine configuration:
    • CPUs: 8
    • Memory: 8.1 GB
  • report

Providers

applehv
  • Before: 32.82 s
  • After: 5.77 s
libkrun (krunkit 0.2.1)
  • Before: 25.87 s
  • After: 7.17 s

Windows

  • Windows 10
  • Number of runs: 10
  • Machine:
    • CPU: Intel Core i7-8665U
    • RAM: 32 GB
    • SSD: 500 GB Samsung 970 Evo Plus
  • Podman machine configuration:
    • CPUs: 8
    • Memory: 2 GB (WSL) | 8.2 GB (Hyper-v)
  • report

Providers

WSL
  • Memory: 2 GB
  • Before: 35.25 s
  • After: 78.31 s
Hyper-V
  • Memory: 8.2 GB
  • Before: 362.70 s
  • After: 51.66 s

Checklist

Ensure you have completed the following checklist for your pull request to be reviewed:

  • Certify you wrote the patch or otherwise have the right to pass it on as an open-source patch by signing all
    commits. (git commit -s). (If needed, use git commit -s --amend). The author email must match
    the sign-off email address. See CONTRIBUTING.md
    for more information.
  • Referenced issues using Fixes: #00000 in commit message (if applicable)
  • Tests have been added/updated (or no tests are needed)
  • Documentation has been updated (or no documentation changes are needed)
  • All commits pass make validatepr (format/lint checks)
  • Release note entered in the section below (or None if no user-facing changes)

Does this PR introduce a user-facing change?

Added new local artifact add API endpoint (`libpod/local/artifacts/add`) for loading artifacts from local files
Image and artifact load endpoints now require absolute paths for local file operations to improve security and prevent path ambiguity

mheon and others added 30 commits October 24, 2025 10:51
Signed-off-by: Matt Heon <matthew.heon@pm.me>
Signed-off-by: Matt Heon <mheon@redhat.com>
Signed-off-by: mheon <7735048+mheon@users.noreply.github.com>
This change adds a .CreatedAt format option to the podman artifact ls
command to match the behavior of podman images --format CreatedAt.

The .Created field continues to display human-readable elapsed time
(e.g., '6 hours ago'), while the new .CreatedAt field displays the
full timestamp (e.g., '2025-10-23 12:34:56 +0000 UTC').

Changes:
- Refactored artifactListOutput struct to store time.Time value
- Added CreatedAt() method returning full timestamp string
- Added Created() method for human-readable duration
- Updated documentation to include .CreatedAt field
- Added e2e test for .CreatedAt format option

Generated-with: Cursor AI
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Function `SignItem` used the helper `CheckCommand` that got removed as
part of containers#27284. As a result the GH release job failed
https://github.com/containers/podman/actions/runs/18792520254/job/53626352685

This commit address that.

Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
…herry-pick-27352-to-v5.7

[v5.7] Add CreatedAt format option to podman artifact ls
…herry-pick-27382-to-v5.7

[v5.7] Fix Windows Installer GH release
Bump bundled krunkit to 1.1.0. For podman, this release means
better I/O performance due to this libkrun version defaulting to
a more relaxed disk image sync on macOS, and raising the vCPU
limit to the maximum allowed by Hypervisor.framework.

Fixes: containers#27216
Signed-off-by: Sergio Lopez <slp@redhat.com>
…herry-pick-27393-to-v5.7

[v5.7] Bump bundled krunkit from 0.2.2 to 1.1.0
Signed-off-by: Matt Heon <mheon@redhat.com>
Signed-off-by: Matt Heon <mheon@redhat.com>
Signed-off-by: mheon <7735048+mheon@users.noreply.github.com>
The WSL tests for `podman machine` are flaking with unreasonable
frequency right now. Last Friday, I needed to re-run a job 8
times to get it to pass and complete the release of 5.7 RC1. This
is simply not sustainable. Mark the tests allowed-failure until
this can be resolved.

Signed-off-by: Matt Heon <mheon@redhat.com>
…herry-pick-27401-to-v5.7

[v5.7] Allow failures on WSL machine tests
The windows installer doesn't like -rc's because it's not strictly semver, but this error can be suppressed.

Signed-off-by: Ashley Cui <acui@redhat.com>
…herry-pick-27408-to-v5.7

[v5.7] Allow RC Windows Installer to be built
Bump bundled krunkit to 1.1.1. This is a minor, expedited release
to fix a library linking problem.

Fixes: containers#27427
Signed-off-by: Sergio Lopez <slp@redhat.com>
See:
- teemtee/tmt#4047
- teemtee/tmt#4026

Signed-off-by: Cristian Le <git@lecris.dev>
…herry-pick-27428-to-v5.7

[v5.7] Bump bundled krunkit from 1.1.0 to 1.1.1
- Add comprehensive mock registry server for e2e search tests
- Replace quay.io and other external registry calls with local mock
- Improve test reliability by removing network dependencies
- Maintain full test coverage with controlled mock data

Fixes: containers#27304
Fixes: https://issues.redhat.com/browse/RUN-3623

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
…leanly

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
…herry-pick-27140-to-v5.7

[v5.7] Add tmt integration plan
…herry-pick-27333-to-v5.7

[v5.7] Eliminate network dependencies in `podman search` e2e tests with mock registry
Fixes a regression introduced by b2e6d53 that made always failing the
match of the WSL image from the registry with the image in the local
cache. The result was that the WSL machine image was always pulled from
quay.io even if an identical image was in the local cache.

Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
TomSweeneyRedHat and others added 21 commits December 5, 2025 17:09
Bump common to v0.66.1 in order to get some new
Windows functionality in for Podman v5.7.1

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
…y/common-v0.66.1-v5.7

[v5.7] Bump common to v0.66.1
The WSL machine start was using the function FindExecutablePeer that
ignores user configuration (helper_binaries_dir). FindHelperBinary
instead is used when starting the machine for the rest of the providers
and honors user configuration.

This commit requires containers/container-libs@4877783

Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
…ries-cp

[v5.7] Replace FindExecutablePeer with FindHelperBinary
This was not working when emulating Linux container images on FreeBSD.
The code to handle host devices on FreeBSD relies on the container
having a devfs mount. Unfortunately, the Linux emulation code which adds
this was happening after the host device handling. This changes the
logic so that host device management happens after Linux emulation.

Signed-off-by: Doug Rabson <dfr@rabson.org>
There is a couple of newGenericDecompressor function usages, where
returned possibly non-nil `err` is not checked before dereferencing
returned decompressor. It may lead to nil ptr dereferencing.

This commit adds check for `err` to prevent dereferencing potentially
nullable decompressor.

Found by Linux Verification Center (linuxtesting.org) with SVACE

Signed-off-by: Mikhail Dmitrichenko <m.dmitrichenko222@gmail.com>
In function rm variable `report` might be initialized as nil as a result
of call
`registry.ImageEngine().Remove(registry.Context(), args, imageOpts)`.
Then, there is a call `registry.SetExitCode(report.ExitCode)` without
explicit nil check before. Check `len(rmErrors) > 0` doesn't guarantee
that report is a non-nil value.
So such call may lead to nil deref.

This commit adds check `report` for nil before its dereference.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Signed-off-by: Mikhail Dmitrichenko <m.dmitrichenko222@gmail.com>
Signed-off-by: Matt Heon <matthew.heon@pm.me>
The `*os.File` returned by `pathrs.OpenatInRoot` needs to
be closed before returning from `openSymlinkPath`

Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
…herry-pick-27727-to-v5.7

[v5.7] kube play: Fix fd leak when handling symlinks
Signed-off-by: Matt Heon <mheon@redhat.com>
Signed-off-by: Matt Heon <mheon@redhat.com>
Signed-off-by: mheon <7735048+mheon@users.noreply.github.com>
Signed-off-by: Mario Loriedo <mario.loriedo@gmail.com>
(cherry picked from commit 22b10fa)
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
[v5.7] Use explicit download-artifact name and path for win-installer release
Fixes: https://issues.redhat.com/browse/RUN-3385
Fixes: containers#26321

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
(cherry picked from commit 91af437)
Signed-off-by: Jan Rodák <hony.com@seznam.cz>
(cherry picked from commit 2f7094c)
The local API path optimization is ineffective on WSL because of NTFS mounting overhead.

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
(cherry picked from commit d889aeb)
@Honny1 Honny1 added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. 5.8 labels Dec 18, 2025
@github-actions github-actions bot added machine kind/api-change Change to remote API; merits scrutiny and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. 5.8 labels Dec 18, 2025
@Honny1 Honny1 added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. 5.8 labels Dec 18, 2025
@Honny1 Honny1 closed this Dec 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

5.8 do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. kind/api-change Change to remote API; merits scrutiny machine

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Podman-Remote needs api to do local artifact creation or builds.