Commit Graph

21626 Commits

Author SHA1 Message Date
OpenShift Merge Robot e916b4e376
Merge pull request #19714 from rhatdan/umask
podman exec should set umask to match container
2023-08-25 14:52:55 +02:00
OpenShift Merge Robot 584c1e70d0
Merge pull request #19704 from rhatdan/timeout
Set StopTimeout for compat API if not set by client
2023-08-25 05:28:26 -04:00
OpenShift Merge Robot c2bb278a11
Merge pull request #19741 from edsantiago/wait_for_file_content
system tests: try to fix sdnotify flakes
2023-08-25 05:18:08 -04:00
OpenShift Merge Robot 15d2ef84c0
Merge pull request #19644 from vrothberg/server-notify
system service: unset NOTIFY_SOCKET
2023-08-25 04:55:00 -04:00
OpenShift Merge Robot be380461ed
Merge pull request #19705 from n1hility/shared-bind-mnts
Share podman sock bindings with other WSL distros
2023-08-25 04:38:50 -04:00
OpenShift Merge Robot b3439584f6
Merge pull request #19736 from cevich/stop_hello_multiarch_build
Cirrus: Disable only hello multiarch build
2023-08-25 03:57:34 -04:00
Brent Baude d3618719b1 Dedup and refactor image acquisition
As promised in #19596, this pr deduplicates and refactors image
acquisition.  All virt providers that use FCOS as its default now use
the same code.

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2023-08-24 20:52:03 -05:00
Jason T. Greene adf34cbd79 Share podman sock bindings with other WSL distros
Registers a rootless and rootful socket underneath /mnt/wsl/podman-sockets/[machine name]/
This allows podman remote clients on other Linux distributions to access podman.

This also registers the podman root socket under the wheel group, to allow for rootful
linking against /var/run/docker.sock, a use case expected by some clients and APIs.
While this is not recommended practice on a Linux host, a WSL guest is user-isolated
and already enables escalation trivially.

[NO NEW TESTS NEEDED]

Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2023-08-24 16:23:50 -05:00
Jason T. Greene db95e678ad Fix user-mode validation check
Signed-off-by: Jason T. Greene <jason.greene@redhat.com>
2023-08-24 16:23:50 -05:00
Ed Santiago d898ae7f9c system tests: try to fix sdnotify flakes
Unexplained infrequent flakes in sdnotify system tests,
waiting for READY=1.

Hypothesis: race condition between the container sending
the READY string and that string making it through conmon
and socat into the log file.

Solution: don't just check once; keep trying in a loop.
Write a reusable wait_for_file_content() helper function,
and clean up a bunch more tests as long as we're at it.

Fixes: #19724

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-08-24 14:24:57 -06:00
Chris Evich ecf9f9fd8b
Cirrus: Disable only hello multiarch build
The `contrib/hello` directory is needed for some CI tests here and in
buildah.  Further, the build job that produces images from this
directory are currently broken.  Disable the build job, and updte
the README.md to point people at the replacement repo. for this content.

Ref: https://github.com/containers/podman/pull/19730

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-08-24 16:07:25 -04:00
OpenShift Merge Robot 0322b9df9d
Merge pull request #19733 from edsantiago/registry_282
e2e tests: use registry:2.8.2 (was 2.8)
2023-08-24 14:04:11 -04:00
OpenShift Merge Robot 7661ebbc63
Merge pull request #19500 from martinpitt/tmt-revdeps-cockpit-podman
[CI:BUILD] Packit: run cockpit-podman tests in PRs
2023-08-24 13:53:50 -04:00
Daniel J Walsh f32e954b8a
Set StopTimeout for service-container started under podman kube play
Fixes: https://github.com/containers/podman/issues/19139

Service containers are defaulting to 0 seconds for Timeout rather then
the settings in containers.conf.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-08-24 13:24:41 -04:00
Daniel J Walsh d2ec127c13
Set StopTimeout for compat API if not set by client
Currently containers created via DOCKER API without specifying
StopTimeout are defaulting to 0 seconds. This change should
default them to setting in containers.conf normally 10 seconds.

Fixes: https://github.com/containers/podman/issues/19139

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-08-24 13:24:41 -04:00
Daniel J Walsh 6f284dbd46
podman exec should set umask to match container
Fixes: https://github.com/containers/podman/issues/19713

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-08-24 13:20:06 -04:00
Martin Pitt 2c5c2d2134 [CI:BUILD] Packit: run cockpit-podman tests in PRs
See https://cockpit-project.org/blog/tmt-cross-project-testing.html

[NO NEW TESTS NEEDED] - quiesce bot, that whole commit *is* a new test

Signed-off-by: Martin Pitt <mpitt@redhat.com>
2023-08-24 18:29:44 +02:00
OpenShift Merge Robot 32f7bb131a
Merge pull request #19727 from vrothberg/fix-19715
kube: notifyproxy: close once
2023-08-24 12:25:22 -04:00
Urvashi Mohnani 52ed7fce2a Add infra-name annotations to kube gen/play
Add io.podman.annotations.infra.name annotation to kube play so
users can set the name of the infra container created.
When a pod is created with --infra-name set, the generated
kube yaml will have an infraName annotation set that will
be used when playing the generated yaml with podman.

Signed-off-by: Urvashi Mohnani <umohnani@redhat.com>
2023-08-24 11:29:56 -04:00
Daniel J Walsh 6009d16b51
Merge pull request #19732 from containers/renovate/k8s.io-kubernetes-1.x
Update module k8s.io/kubernetes to v1.28.1
2023-08-24 10:28:16 -04:00
Paul Holzinger 6545529df5
Merge pull request #19725 from containers/renovate/github.com-onsi-ginkgo-v2-2.x
Update module github.com/onsi/ginkgo/v2 to v2.12.0
2023-08-24 16:26:15 +02:00
Valentin Rothberg a5f6a4a3bf kube: notifyproxy: close once
Do not close a notifyproxy more than once.  Also polish the backend a
bit to reflect ealier changes from commit 4fa307f.

Fixes: #19715
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-08-24 16:24:28 +02:00
Valentin Rothberg 7a94f8c123 system service: unset NOTIFY_SOCKET
Unset the NOTIFY_SOCKET environment variable after sending the MAIN_PID
and READY message.  This avoids any unintentional side-effects of other
code paths using the socket assuming they'd run in a non-server
short-lived Podman process.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-08-24 16:23:01 +02:00
renovate[bot] 638f994c26
Update module k8s.io/kubernetes to v1.28.1
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-08-24 14:22:41 +00:00
Paul Holzinger 7c9c969815
API attach: return vnd.docker.multiplexed-stream header
The attach API used to always return the Content-Type
`vnd.docker.raw-stream`, however docker api v1.42 added the
`vnd.docker.multiplexed-stream` type when no tty was used.

Follow suit and return the same header for docker api v1.42 and libpod
v4.7.0. This technically allows clients to make a small optimization as
they no longer need to inspect the container to see if they get a raw or
multiplexed stream.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-08-24 16:22:28 +02:00
Valentin Rothberg 60e58f0594 test/apiv2/60-auth.at: use `doesnotexists.podman.io`
`exist.io` actually does exist and is not under our control.  To prevent
flakes, change it to something on `podman.io`.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-08-24 16:22:02 +02:00
Ed Santiago 61dd7f80c2 e2e tests: use registry:2.8.2 (was 2.8)
...in hopes of addressing flake #18355

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-08-24 08:21:29 -06:00
Paul Holzinger 243f365aa4
create apiutils package
Move SupportedVersion() and IsLibpodRequest() to separate package to
avoid import cycle when using it in libpod.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-08-24 16:19:50 +02:00
Paul Holzinger c5b4eb9433
api docs: document stream format
Document the attach, exec and logs output stream format. We use the same
format as docker.

Fixes #19280

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-08-24 16:19:50 +02:00
Chris Evich 4d5bef98f5
Merge pull request #19730 from edsantiago/you_say_hello_and_i_say_goodbye
Revert "Remove `hello` multi-arch image build"
2023-08-24 10:18:36 -04:00
Ed Santiago 70f77efef9 Revert "Remove `hello` multi-arch image build"
This reverts commit 7e0130f75c.

It broke CI, not just on podman but on Buildah too. Buildah bud
tests require the hello subdirectory.

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-08-24 05:16:01 -06:00
Aditya R 82bd56be74
manifest-push: add support for --force-compression
Adds support for --force-compression which allows end-users to force
push blobs with the selected compresison in --compression option, in
order to make sure that blobs of other compression on registry are not
reused.

Signed-off-by: Aditya R <arajan@redhat.com>
2023-08-24 13:36:04 +05:30
Aditya R 469ace0910
push: add support for --force-compression
Adds support for --force-compression which allows end-users to force
push blobs with the selected compresison in --compression option, in
order to make sure that blobs of other compression on registry are not
reused.

Is equivalent to: force-compression here: https://docs.docker.com/build/exporters/#compression

Closes: https://github.com/containers/podman/issues/18660

Signed-off-by: Aditya R <arajan@redhat.com>
2023-08-24 13:35:58 +05:30
renovate[bot] 202cc433af
Update module github.com/onsi/ginkgo/v2 to v2.12.0
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-08-23 23:41:24 +00:00
OpenShift Merge Robot 7c0e926820
Merge pull request #19719 from cevich/stop_building_hello
[CI:DOCS] Remove `hello` multi-arch image build
2023-08-23 16:13:23 -02:30
OpenShift Merge Robot c07f46e15c
Merge pull request #19630 from rhatdan/kube
Expand env variables for cmds/entrypoint with format $(ENV)
2023-08-23 13:56:38 -02:30
Chris Evich 7e0130f75c
Remove `hello` multi-arch image build
Moved to https://github.com/containers/PodmanHello

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-08-23 12:10:22 -04:00
OpenShift Merge Robot f29986178e
Merge pull request #19710 from vrothberg/df-benchmarks
[CI:DOCS] hack/perf/system-df.sh: add `df` benchmarks
2023-08-23 10:53:23 -02:30
Valentin Rothberg 1b0e64a103 hack/perf/system-df.sh: add `df` benchmarks
The performance issue in #19467 drove me to add a benchmark for
system-df to avoid regressing on it in the future.

Comparing current HEAD to v4.6.0 yields

```
/home/vrothberg/containers/podman/bin/podman system df ran
201.47 times faster than /usr/bin/podman system df
```

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-08-23 14:17:27 +02:00
OpenShift Merge Robot 7f6bcbba81
Merge pull request #19709 from vrothberg/vendor-storage
vendor c/storage@6902c2d
2023-08-23 09:29:32 -02:30
OpenShift Merge Robot d22c336287
Merge pull request #19707 from sstosh/cgroupv1-limit-ignore
Ignore the resource limits on cgroups V1 rootless systems
2023-08-23 09:26:55 -02:30
Daniel J Walsh 148d95d8df
Expand env variables for cmds/entrypoint with format $(ENV)
Kubernetes supports expanding $(FOOBAR) as environment variables within
the kube.YAML. When using podman kube play, we need to do the same, for
supporting these YAML files.

Fixes: #15983

Signed-off-by: Chee Hau Lim <ch33hau@gmail.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-08-23 07:56:17 -04:00
OpenShift Merge Robot a9c98770e6
Merge pull request #19557 from n1hility/automatic-ports
Implement automatic port reassignment on Windows
2023-08-23 06:49:11 -02:30
OpenShift Merge Robot 2978addf78
Merge pull request #19703 from baude/stopgvproxyfixups
Fixups for stopping gvproxy
2023-08-23 06:18:14 -02:30
Valentin Rothberg e092f887fe vendor c/storage@6902c2d
Mainly to merge fixes for #19467 into the main branch.

Fixes: #19467
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-08-23 10:47:41 +02:00
Toshiki Sonoda c416e45766 Ignore the resource limits on cgroups V1 rootless systems
This is a regression for #18052.
When podman ignores the resource limits, s.ResourceLimits needs to be
nil.

[NO NEW TESTS NEEDED]

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2023-08-23 13:58:13 +09:00
Brent Baude 9e680cbc63 Fixups for stopping gvproxy
Paul found logic errors in my earlier code for finding processes and
sending signals.  Some of the logic errors are associated with how
methods behave on different operating systems.  Created a darwin and
linux approach and a windows approach.

Signed-off-by: Brent Baude <bbaude@redhat.com>

[NO NEW TESTS NEEDED]
2023-08-22 16:00:15 -05:00
OpenShift Merge Robot 7bd60867de
Merge pull request #19700 from cevich/remove_lock_test
[CI:DOCS] Revert "GHA: Closed issue/PR comment-lock test"
2023-08-22 17:37:04 -02:30
Chris Evich 21c9517b5e
Revert "GHA: Closed issue/PR comment-lock test"
This reverts commit f0e8e79c97.
This is intentional, it was needed for testing. See

Signed-off-by: Chris Evich <cevich@redhat.com>
2023-08-22 14:51:24 -04:00
OpenShift Merge Robot 5e295a940d
Merge pull request #19691 from cevich/lock_closed_issues
[skip-ci] Lock closed issues and PRs
2023-08-22 16:05:21 -02:30