Commit Graph

26312 Commits

Author SHA1 Message Date
lstocchi
ab89922f4b hyperv should reuse hvsock registry entries when possible
Previously, each new HyperV Podman machine required creating new hvsock
registry entries, necessitating administrator privileges.

This change modifies the HyperV provider to reuse existing hvsock
entries if found. This is possible due to Podman's current
limitation of running only one HyperV machine at a time.

As a result, administrator privileges are only needed for the first initial
machine setup (when the registry is empty). Subsequent machines can be created by users in the
"Hyper-V Administrators" group without being Admin.

Hvsock entries are no longer deleted on each machine removal; cleanup
is handled when the last machine gets removed.

Signed-off-by: lstocchi <lstocchi@redhat.com>
2025-11-20 16:51:31 +01:00
lstocchi
b62c82bff6 move HasAdminRights to windows pkg
this commit moves the HasAdminRights func from the wsl package to a generic windows package as this could also be used by the HyperV provider.

Signed-off-by: lstocchi <lstocchi@redhat.com>
2025-11-20 15:20:57 +01:00
openshift-merge-bot[bot]
7cd9b81b43 Merge pull request #26727 from ryanmccann1024/feature/26588-exec-no-session
feat(exec): Add --no-session flag for improved performance
2025-11-20 10:28:15 +00:00
openshift-merge-bot[bot]
dfdd3b5074 Merge pull request #27557 from baude/issue27556
Ignore prompt if stdin not a tty on machine start
2025-11-20 10:03:32 +00:00
Brent Baude
6541fc4fb2 Merge pull request #27510 from baude/fakehyperv
fake images: windows hyperv
2025-11-19 12:12:22 -06:00
Brent Baude
3d566d85cf Ignore prompt if stdin not a tty on machine start
When starting a machine and the user has not explicitly passed
-u=true|false AND stdin is a not a tty, we should not prompt to update
connections.

Fixes: #27556

Signed-off-by: Brent Baude <bbaude@redhat.com>
2025-11-19 11:50:25 -06:00
ryanmccann1024
61cbc0c3ee feat(exec): Add --no-session flag for improved performance
Fixes: #26588

For use cases like HPC, where `podman exec` is called in rapid succession, the standard exec process can become a bottleneck due to container locking and database I/O for session tracking.

This commit introduces a new `--no-session` flag to `podman exec`. When used, this flag invokes a new, lightweight backend implementation that:

- Skips container locking, reducing lock contention
- Bypasses the creation, tracking, and removal of exec sessions in the database
- Executes the command directly and retrieves the exit code without persisting session state
- Maintains consistency with regular exec for container lookup, TTY handling, and environment setup
- Shares implementation with health check execution to avoid code duplication

The implementation addresses all performance bottlenecks while preserving compatibility with existing exec functionality including --latest flag support and proper exit code handling.

Changes include:
- Add --no-session flag to cmd/podman/containers/exec.go
- Implement lightweight execution path in libpod/container_exec.go
- Ensure consistent container validation and environment setup
- Add comprehensive exit code testing including signal handling (exit 137)
- Optimize configuration to skip unnecessary exit command setup

Signed-off-by: Ryan McCann <ryan_mccann@student.uml.edu>
Signed-off-by: ryanmccann1024 <ryan_mccann@student.uml.edu>
2025-11-19 12:44:48 -05:00
openshift-merge-bot[bot]
5c48d02fe8 Merge pull request #27562 from Honny1/fix-ci
test/system: remove deprecated cgroupsv1 skip check
2025-11-19 17:06:55 +00:00
Jan Rodák
d22e50eac9 test/system: remove deprecated cgroupsv1 skip check
Remove skip_if_rootless_cgroupsv1 call from quadlet tests since
cgroupsv1 is deprecated and no longer needs special handling

Signed-off-by: Jan Rodák <hony.com@seznam.cz>
2025-11-19 14:26:25 +01:00
openshift-merge-bot[bot]
fb7e99786e Merge pull request #27384 from flouthoc/multi-file-quadlet
quadlet install: add support for multiple quadlets in a single file
2025-11-18 16:01:08 +00:00
Brent Baude
7a2afdf1db Merge pull request #27553 from containers/renovate/google.golang.org-grpc-1.x
fix(deps): update module google.golang.org/grpc to v1.77.0
2025-11-18 08:18:20 -06:00
renovate[bot]
1e5a789bef fix(deps): update module google.golang.org/grpc to v1.77.0
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-18 10:40:50 +00:00
openshift-merge-bot[bot]
d1a3a4adf0 Merge pull request #27539 from containers/renovate/github.com-opencontainers-selinux-1.x
fix(deps): update module github.com/opencontainers/selinux to v1.13.1
2025-11-18 09:16:00 +00:00
flouthoc
c22c3271bb quadlet install: multiple quadlets from single file should share app
Quadlets installed from `.quadlet` file now belongs to a single
application, anyone file removed from this application removes all the
other files as well.

Assited by: claude-4-sonnet

Signed-off-by: flouthoc <flouthoc.git@gmail.com>
2025-11-17 10:23:28 -08:00
renovate[bot]
bfd51c2715 fix(deps): update module github.com/opencontainers/selinux to v1.13.1
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-15 00:48:51 +00:00
openshift-merge-bot[bot]
af91cae1c5 Merge pull request #27271 from lsm5/podman6-no-cgv1
Podman6: Remove cgroupsv1
2025-11-14 17:03:59 +00:00
openshift-merge-bot[bot]
78b3f862a4 Merge pull request #27537 from containers/renovate/github.com-godbus-dbus-v5-5.x
fix(deps): update module github.com/godbus/dbus/v5 to v5.2.0
2025-11-14 16:47:24 +00:00
openshift-merge-bot[bot]
ec2567ed48 Merge pull request #27534 from matejvasek/revert-copyuidgid-inversion
Revert "Fix copyUIDGID parameter inversion in Docker compat API"
2025-11-14 14:41:29 +00:00
renovate[bot]
c9d99dc98a fix(deps): update module github.com/godbus/dbus/v5 to v5.2.0
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-14 12:42:37 +00:00
openshift-merge-bot[bot]
d388f9bbd2 Merge pull request #27342 from inknos/run-3578
Remove hardcoded refs from ociartifact code
2025-11-14 12:39:32 +00:00
Matej Vašek
65411d53c9 Revert "Fix copyUIDGID parameter inversion in Docker compat API"
This reverts commit 2b848cca36.

The official Docker API documentation was misleading here.
Testing shown that old podman behaviour was correct.
In docker copyUIDGID=true means that primary container uid/gid is used,
not the uid/gid from the tar stream.

Signed-off-by: Matej Vašek <matejvasek@gmail.com>
2025-11-14 12:39:04 +01:00
Paul Holzinger
6f9bf07a34 swagger: fix for new docker/moby module conflict
image got converted to the new docker modules which were finally renamed
to moby[1]. Podman however still uses docker so now the swagger lookup
seems to find duplicated types which in general breaks the generation so
exclude the new module for now until we convert podman and fix the new
type issues swagger found.

[1] https://github.com/containers/container-libs/pull/459

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2025-11-14 12:29:27 +01:00
openshift-merge-bot[bot]
d848f9f79d Merge pull request #27503 from baude/issue27491
Fix regression in podman machine ssh
2025-11-14 01:28:54 +00:00
Nicola Sella
df4905d68b Remove hardcoded refs from ociartifact code
Fixes: https://issues.redhat.com/browse/RUN-3578

Signed-off-by: Nicola Sella <nsella@redhat.com>
2025-11-13 22:57:21 +01:00
openshift-merge-bot[bot]
d3c5c5d219 Merge pull request #27473 from lsm5/deprecation-notice-update
golangci-lint bump and deprecation cleanups
2025-11-13 14:13:52 +00:00
openshift-merge-bot[bot]
ac2d567910 Merge pull request #27517 from containers/renovate/pytest-9.x
chore(deps): update dependency pytest to v9.0.1
2025-11-12 21:01:31 +00:00
renovate[bot]
613ac5bd73 chore(deps): update dependency pytest to v9.0.1
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-12 20:40:53 +00:00
Lokesh Mandvekar
f47f74cad6 pkg/specgen/generate/kube: nolint and FIXMEs for seccomp deprecations
Ref: https://github.com/containers/podman/issues/27501

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:30 -05:00
Lokesh Mandvekar
96aba07d95 libpod/container_internal.go: util.SizeOfPath -> directory.Size
- Remove deprecated util.SizeOfPath

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:29 -05:00
Lokesh Mandvekar
f11392c719 Remove deprecated fields ctrConfig.[StaticIP,StaticMAC]
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:29 -05:00
Lokesh Mandvekar
3842f4d4e5 pkg/specgen: Remove deprecated CNINetworks
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:29 -05:00
Lokesh Mandvekar
5d46171b7d bump golangcilint to 2.6.0
Obsoletes: #27407

Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:29 -05:00
Lokesh Mandvekar
a3fcf52a1c Fix deprecation notice to make gocritic happy.
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:35:29 -05:00
Lokesh Mandvekar
145540fed4 Remove ContainerStats.PerCPU: CGV1 only
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
bb3c8b9ecd docs: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
036bf7b44f test/system: delete CgV1 skips and skipped CgV2 tests
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
4970fd26e4 test/e2e: delete CgV1 skips, delete tests skipped on Cgv2
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
5e02967fd7 pkg/api/handlers/compat/containers_create.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
6f43a66629 cmd/podman/system/service_abi_linux.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:34 -05:00
Lokesh Mandvekar
5d7358d2bf pkg/api/handlers/libpod/containers_stats.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
30d07aa0c8 pkg/domain/infra/abi/containers.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
a994aef330 pkg/domain/infra/abi/pods_stats.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
850bae519e pkg/specgen/namespaces.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
c98c50ec76 libpod/pod_api.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
06bc277ad8 libpod/util_linux.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
a12b3e97d2 libpod/runtime.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
faa551a921 libpod/runtime_ctr.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
72f8a01d9d pkg/specgen/generate/validate_linux.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
2e6a923f1e pkg/domain/infra/runtime_libpod.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:33 -05:00
Lokesh Mandvekar
cb91d90835 libpod/runtime_pod_linux.go: Remove Cgroups v1
Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com>
2025-11-12 15:15:32 -05:00