19579 Commits

Author SHA1 Message Date
69f112a8bf Merge pull request #19200 from rhatdan/secret1
Add secret support to podman login
2023-07-13 03:06:50 -04:00
8c16322a84 machine start: qemu: wait for SSH readiness
During the exponential backoff waiting for the machine to be fully up
and running, also make sure that SSH is ready.  The systemd dependencies
of the ready.service include the sshd.service among others but that is
not enough.

Other CoreOS users reported the same issue on IRC, so I feel fairly
confident to use the pragmatic approach of making sure SSH works on the
client side.  #17403 is quite old and there are other pressing machine
issues that need attention.

[NO NEW TESTS NEEDED]

Fixes: #17403
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-13 08:57:07 +02:00
20879aba0e Merge pull request #19188 from mheon/fix_19159
Fix container errors not being sent via pod removal API
2023-07-12 17:33:54 -04:00
12dc546fc1 [CI:BUILD] Packit: downstream task action fix
The downstream `pre-sync` task action script needs GOPATH to be
specified for the golist tool mentioned in the script to work.

[NO NEW TESTS NEEDED]

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-07-12 15:20:29 -04:00
2b2c4453f1 Fix container errors not being sent via pod removal API
When I reworked pod removal to provide more detailed errors
(including per-container errors, not just a single multierror
with all errors squashed), I made it part of the struct returned
by the REST API and assumed that would be enough to get errors
through to clients. Unfortunately, in case of an overarching
error removing the pod (as any error with any container would
cause), we don't send the response struct that would include the
container errors - we just send a standardized REST error. We
could work around this with custom, potentially backwards
incompatible error handling for the REST pod delete endpoint, or
we could just do what was done before, and package up all the
errors in a multierror to send to the other side. Of those
options, the multierror seems far simpler.

Fixes #19159

Signed-off-by: Matt Heon <mheon@redhat.com>
2023-07-12 14:50:15 -04:00
6ec261e7ac Add missing return after utils.InternalServerError()
Signed-off-by: Erik Sjölund <erik.sjolund@gmail.com>
2023-07-12 20:47:16 +02:00
cd58306a81 Merge pull request #19207 from Luap99/mv-dns
netavark: macvlan networks keep custom nameservers
2023-07-12 14:09:51 -04:00
dcf0a3cfc2 Merge pull request #19203 from sstosh/remote-play-kube-userns
remote: fix podman-remote play kube --userns
2023-07-12 14:07:14 -04:00
d1950869ab Update cmd/podman/login.go
Co-authored-by: Ashley Cui <ashleycui16@gmail.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-07-12 11:09:16 -04:00
cce8501a5b [CI:DOCS] Reformat and reorder table with --userns options
Reorder the table with --userns options to match the description below.
Also, reformat the Markdown to be better readable in source form.

Signed-off-by: Philipp Wagner <phw@ibm.com>
2023-07-12 16:05:06 +02:00
9d9f4aaafe Merge pull request #19006 from deuill/quadlet-volume-network-names
Allow setting volume and network names in Quadlet
2023-07-12 08:53:38 -04:00
d497eb369c Add secret support to podman login
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-07-12 08:45:02 -04:00
2a9b9bb53f netavark: macvlan networks keep custom nameservers
The change to use the custom dns server in aardvark-dns caused a
regression here because macvlan networks never returned the nameservers
in netavark and it also does not make sense to do so.

Instead check here if we got any network nameservers, if not we then use
the ones from the config if set otherwise fallback to host servers.

Fixes #19169

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-12 14:07:34 +02:00
958191aedc Merge pull request #19199 from containers/renovate/github.com-container-orchestrated-devices-container-device-interface-0.x
fix(deps): update module github.com/container-orchestrated-devices/container-device-interface to v0.6.0
2023-07-12 07:26:18 -04:00
99ca4435fc Merge pull request #19197 from containers/renovate/go-github.com/gin-gonic/gin-vulnerability
chore(deps): update module github.com/gin-gonic/gin to v1.9.1 [security]
2023-07-12 07:21:00 -04:00
6fc7c48421 Merge pull request #19190 from containers/renovate/github.com-containers-libhvee-0.x
fix(deps): update module github.com/containers/libhvee to v0.3.0
2023-07-12 07:18:29 -04:00
c5006f4786 Merge pull request #19204 from Luap99/vendor-tidy
go mod: no longer use 1.18
2023-07-12 06:26:47 -04:00
c6b5b9a02c remote: fix podman-remote play kube --userns
Fix `podman play kube --userns` to work in remote environment.

Related: #17392

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2023-07-12 18:47:36 +09:00
441af003ac fix(deps): update container-device-interface to v0.6.0
[NO NEW TESTS NEEDED]

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-12 11:37:59 +02:00
d3ac265fc5 Merge pull request #19196 from vrothberg/bz-2180483
system service: unset listen fds on tcp
2023-07-12 05:05:31 -04:00
656ad760f6 go mod: no longer use 1.18
1.18 is EOL and we should not have to set this since the current
versions should generate compatible go.sum files anyway.

This is an attempt to fix broken renovate PRs which create a different
go.sum and thus do not pass CI checks.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-12 10:36:22 +02:00
aeef403cd2 fix(deps): update module github.com/containers/libhvee to v0.3.0
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-12 10:31:35 +02:00
6fd4ae6d29 chore(deps): update module github.com/gin-gonic/gin to v1.9.1 [security]
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-12 10:30:34 +02:00
5444073581 Merge pull request #19186 from rhatdan/codespell
Run codespell on code
2023-07-11 20:09:20 -04:00
0dcfe6e069 Run codespell on code
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-07-11 16:44:22 -04:00
1be2ec1d4f Merge pull request #19193 from Luap99/hostname-alias
add hostname to network alias
2023-07-11 12:19:02 -04:00
b994f8610d Merge pull request #19131 from baude/applehvpass2
AppleHV enablement pass #2
2023-07-11 10:59:58 -04:00
3ad55f48bb system service: unset listen fds on tcp
Disable leaking the LISTEN_* variables into containers which are
observed to be passed by systemd even without being socket activated as
described in https://access.redhat.com/solutions/6512011.

[NO NEW TESTS NEEDED] - Ultimately, the solution 6512011 should be updated.

Fixes: bugzilla.redhat.com/show_bug.cgi?id=2180483
Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-11 16:44:27 +02:00
b1dd0a3350 Merge pull request #19189 from pjannesen/issue/19175
Fix: cgroup is not set: internal libpod error after os reboot
2023-07-11 10:43:22 -04:00
f1c68b79eb add hostname to network alias
We use the name as alias but using the hostname makes also sense and
this is what docker does. We have to keep the short id as well for
docker compat.

While adding some tests I removed some duplicated tests that were
executed twice for nv for no reason.

Fixes #17370

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-11 15:38:24 +02:00
b6ec2127b8 libpod: set cid network alias in setupContainer()
Since we have sqlite there is no point in duplicating this acroos two db
backends. Just set earlier when we validate the networks anyway.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-11 15:16:11 +02:00
bd85be42fd Merge pull request #19100 from edsantiago/pasta_better_cleanup
pasta tests: automatically determine test parameters
2023-07-11 09:02:47 -04:00
4e96686e9d AppleHV enablement pass #2
* Use vfkit command line assembly
* Inject ignition file into guest using http over vsock
* Ready notification through use of vsock

[NO NEW TESTS NEEDED]

Signed-off-by: Brent Baude <bbaude@redhat.com>
2023-07-11 06:36:10 -05:00
e6dbb422ef Merge pull request #19191 from sstosh/e2e-fix-username
e2e: Fetch the correct user name
2023-07-11 04:48:14 -04:00
72a1857e43 e2e: Fetch the correct user name
When fetching the user name, you need to use User.Username
instead of User.Name, as with other tests.

Signed-off-by: Toshiki Sonoda <sonoda.toshiki@fujitsu.com>
2023-07-11 13:51:47 +09:00
77b36ca35e Merge pull request #19102 from jakecorrenti/kube-generate-print-annotations
Add `--no-trunc` flag to maintain original annotation length
2023-07-10 22:41:39 -04:00
7b54fd84ec Add --no-trunc flag to maintain original annotation length
Adds a `--no-trunc` flag to `podman kube generate` preventing the
annotations from being trimmed at 63 characters. However, due to
the fact the annotations will not be trimmed, any annotation that is
longer than 63 characters means this YAML will no longer be Kubernetes
compatible. However, these YAML files can still be used with `podman
kube play` due to the addition of the new flag below.

Adds a `--no-trunc` flag to `podman kube play` supporting YAML files with
annotations that were not truncated to the Kubernetes maximum length of
63 characters.

Signed-off-by: Jake Correnti <jakecorrenti+github@proton.me>
2023-07-10 18:02:53 -04:00
600de05e3b Fix TCP probes when the optional host field is not given
Signed-off-by: Hedayat Vatankhah <hedayat.fwd@gmail.com>
2023-07-11 01:00:57 +03:30
ac3a115c33 Add support for using port names in Kubernetes health probes
Closes #18645

Signed-off-by: Hedayat Vatankhah <hedayat.fwd@gmail.com>
2023-07-11 01:00:57 +03:30
4494cefbca Fix: cgroup is not set: internal libpod error after os reboot
[NO NEW TESTS NEEDED]
Closes #19175

Signed-off-by: Peter Jannesen <peter@jannesen.com>
2023-07-10 22:37:43 +02:00
932fae4028 Allow setting volume and network names in Quadlet
This commit extends `Volume` and `Network` unit definitions with two
additional parameters, `VolumeName` and `NetworkName`, which will,
respectively, set a user-defined name for the corresponding volume and
network. This is similar to how the `ContainerName` directive currently
works, and should allow for smoother transitions to Quadlet-managed
resources.

Closes: #19003
Signed-off-by: Alex Palaistras <alex@deuill.org>
2023-07-10 20:33:19 +01:00
427b959a1c pasta tests: automatically determine test parameters
...from the test name. Eliminates scary duplication.

Followup to #19053: instead of cross-checking pasta test args
against test name, eliminate the args entirely. Determine
them all from the @test name itself.

Example:
   "TCP translated port range forwarding, IPv4, loopback"
     |  |          |    |     |           |     +-- iftype=loopback
     |  |          |    |     |           +-------- ip_ver=4
     |  |          |    |     +-------------------- bytes=1
     |  |          |    +-------------------------- range=3
     |  |          +------------------------------- (ignored)
     |  +------------------------------------------ delta=1
     +--------------------------------------------- proto=tcp

Signed-off-by: Ed Santiago <santiago@redhat.com>
2023-07-10 13:07:15 -06:00
d31b9eb9e7 Merge pull request #19170 from dfr/freebsd-mtab
libpod: don't make a broken symlink for /etc/mtab on FreeBSD
2023-07-10 15:02:14 -04:00
eb9d44241e Merge pull request #19004 from rhatdan/secret
Add --replace flag to podman secret create
2023-07-10 14:59:29 -04:00
7b08e024c1 Merge pull request #19180 from vrothberg/fix-19147
manifest inspect: support authentication
2023-07-10 14:40:29 -04:00
8c071ca653 Merge pull request #19179 from Luap99/syslog
make --syslog errors non fatal
2023-07-10 14:37:36 -04:00
79d3453f32 Merge pull request #19182 from Luap99/slow-remote-version
test/e2e: wait for socket
2023-07-10 13:16:51 -04:00
97fd03ccdf test/e2e: wait for socket
Do not use podman info/version as they are expensive and clutter the log
for no reason. Just checking if we can connect to the socket should be
good enough and much faster.

Fix the non existing error checking, so that we actually see an useful
error when this does not work.

Also change the interval, why wait 2s for a retry lets take 100ms steps
instead.

Fixes #19010

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-10 17:27:11 +02:00
a69194b02f manifest inspect: support authentication
Previous tests have worked by pure chance since the client and server
ran on the same host; the server picked up the credentials created by
the client login.

Extend the gating tests and add a new integration test which is further
capable of exercising the remote code.

Note that fixing authentication support requires adding a new
`--authfile` CLi flag to `manifest inspect`.  This will at least allow
for passing an authfile to be bindings.  Username and password are not
yet supported.

Signed-off-by: Valentin Rothberg <vrothberg@redhat.com>
2023-07-10 16:26:19 +02:00
70428baef3 api: fix slow version endpoint
This endpoint queried the same package versions twice causing it to be
slower than info. Because it already called info we can just reuse the
package versions from there.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
2023-07-10 15:46:45 +02:00