containers / podman-desktop

Podman Desktop is the best free and open source tool to work with Containers and Kubernetes for developers. Get an intuitive and user-friendly interface to effortlessly build, manage, and deploy containers and Kubernetes — all from your desktop.
https://podman-desktop.io
Apache License 2.0
4.65k stars 294 forks source link

After upgrading podman-desktop-1.9.1 (podman 4.9.4) to podman-desktop-1.10.2 (podman 5.0.2) images cannot be pulled any more behind corporate proxy #7129

Closed jochenr closed 4 months ago

jochenr commented 4 months ago

Bug description

Hi,

after I upgraded podman-desktop and podman on my windows machine

I cannto pull images any more.

podman pull quay.io/podman/hello

returns

Trying to pull quay.io/podman/hello:latest...
Error: initializing source docker://quay.io/podman/hello:latest: pinging container registry quay.io: Get "https://quay.io/v2/": dial tcp x.x.x.x:443: i/o timeout

With version 1.9.1 / 4.9.4 combination everything worked fine, but with versions 1.10.2 / 5.0.2 I cannot pull any images.

I did an update/upgrade installtion and after facing this error I did a complete uninstall/re-install. Unfortunately with the same result.

Since I am in an restricted corporate environmant I have done everything mentionesd in https://podman-desktop.io/docs/proxy proxy, proxy-certificates, user mode networking

The same settings that worked with the previous versions....

The interesting fact is that I can pull images if I ssh into my podman-machine:


PS C:\> podman machine ssh
Connecting to vm podman-machine-default. To close connection, use `~.` or `exit`
Last login: Tue May  7 18:18:47 2024 from ::1
[root@myMachine ~]# podman pull quay.io/podman/hello
WARN[0000] Using cgroups-v1 which is deprecated in favor of cgroups-v2 with Podman v5 and will be removed in a future version. Set environment variable `PODMAN_IGNORE_CGROUPSV1_WARNING` to hide this warning.
Trying to pull quay.io/podman/hello:latest...
Getting image source signatures
Copying blob 5ded08933881 done   |
Copying config 0e9d283b97 done   |
Writing manifest to image destination
0e9d283b971f583c9110a9438dce74a5f89e5c9b0654c7f9053a904aa4aab830
[root@myMachine ~]#

So I think proxy and proxy-certificates settings are correct.

For me it seems there is an issue "between" podman-desktop/podman on windows connecting to the WSL podman machine.

Operating system

Windows 10 Enterprise (build 19045.4291)

Installation Method

Installer from website/GitHub releases

Version

1.10.2

Steps to reproduce

No response

Relevant log output

No response

Additional context

No response

benoitf commented 4 months ago

hello @jochenr could you fetch the airgap binary, the podman machine is in the installer so it may not try to fetch quay.io

closing as it's a dup of https://github.com/containers/podman-desktop/issues/6836

jochenr commented 4 months ago

Hi @benoitf ,

sorry, not the airgapped setup didn't help. Meanwhile I tried 4 times with complete uninstall and reinstall (cleaning up everything in my user-home). 2 times with the normal installer 2 times with the airgapped installer....always the same result.

The main difference to #6836 is that I can install/create the podman machine without any problems. Podman-desktop was even able to download the podman installer

But connections to any registry ( I tried quay.io, docker.io, github/ghcr.io) for downloading acontainer-images are not possible from the powershell and git-basg terminal. But downloading images works, if I ssh into podman machine and pull from the bash inside my podman machine.

So I think it's not a dublicate of #6836.

Please repoen. Thank you

lepus commented 4 months ago

@benoitf THis is not a dup of #6836. The problem is not the installation. The issue is with the pulling container images from a registry. The installation itself is fine but when we try to pull an image the proxy environment variables were ignored and we get an i/o timeout

$ env | grep proxy
HTTPS_PROXY=http://xxxxx.xxx:8080

$ podman pull ubi8-micro
Resolved "ubi8-micro" as an alias (/etc/containers/registries.conf.d/000-shortnames.conf)
Trying to pull registry.access.redhat.com/ubi8-micro:latest...
Error: initializing source docker://registry.access.redhat.com/ubi8-micro:latest: pinging container registry registry.access.redhat.com: Get "https://registry.access.redhat.com/v2/": dial tcp 2.23.209.6:443: i/o timeout

Could you please reopen that issue.

lepus commented 4 months ago

It seems there is a problem with escaping special chars in /etc/systemd/system.conf.d/default-env.conf If I remove the \ in front of the commas it works fine

# created by podman
DefaultEnvironment=https_proxy=http://myproxy.com:8080
DefaultEnvironment=no_proxy=foo\,localhost
DefaultEnvironment=HTTPS_PROXY=http://myproxy.com:8080
DefaultEnvironment=NO_PROXY=foo\,localhost

# changed to
DefaultEnvironment=https_proxy=http://myproxy.com:8080
DefaultEnvironment=no_proxy=foo,localhost
DefaultEnvironment=HTTPS_PROXY=http://myproxy.com:8080
DefaultEnvironment=NO_PROXY=foo,localhost