podman icon indicating copy to clipboard operation
podman copied to clipboard

podman-run doesn't support --tls-verify parameter

Open guits opened this issue 5 years ago • 4 comments

when executing a podman run command, if the image wasn't explicitly pulled with podman pull prior to that it would fail if the registry doesn't use https.

[root@ceph-test ~]# podman run --rm localhost:5000/ceph-devel:test cat /etc/redhat-release
Trying to pull localhost:5000/ceph-devel:test...
  Get "https://localhost:5000/v2/": http: server gave HTTP response to HTTPS client
Error: Error initializing source docker://localhost:5000/ceph-devel:test: error pinging docker registry localhost:5000: Get "https://localhost:5000/v2/": http: server gave HTTP response to HTTPS client
[root@ceph-test ~]# podman pull --tls-verify=false localhost:5000/ceph-devel:test
Trying to pull localhost:5000/ceph-devel:test...
Getting image source signatures
Copying blob a229e7669eac skipped: already exists
Copying blob 686870bf1ae8 skipped: already exists
Copying blob 7d1e6e12e544 skipped: already exists
Copying blob 4c9e9b43937d skipped: already exists
Copying blob 53d8b30d138c skipped: already exists
Copying blob 889524391d55 skipped: already exists
Copying blob 38378181f1d3 [--------------------------------------] 0.0b / 0.0b
Copying config 6ca1f9851e done
Writing manifest to image destination
Storing signatures
6ca1f9851e75600685c5510b72e956b07165de4f23d40129d224f803da2099c8
[root@ceph-test ~]# podman run --rm localhost:5000/ceph-devel:test cat /etc/redhat-release
CentOS Linux release 8.4.2105
[root@ceph-test ~]#

The --tls-verify parameter seems to be scoped to pull/push subcommands only. Is there any chance this option could be consumed by the podman run command?

Yes, I could edit /etc/containers/registries.conf and add my registry in [registries.insecure] but in a large cluster context, this is not really convenient.

podman version:

[root@ceph-test ~]# podman --version
podman version 3.0.2-dev

Thanks!

guits avatar Aug 04 '21 14:08 guits

Interested in opening a PR? podman run, create need it.

podman build has a --tls-verify

rhatdan avatar Aug 04 '21 19:08 rhatdan

/assign

Shivkumar13 avatar Aug 04 '21 21:08 Shivkumar13

Interested in opening a PR? podman run, create need it.

podman build has a --tls-verify

@rhatdan why not, tried this in #11138

I'm definitely not a Go expert though. I'm not sure this is enough, perhaps I'm missing something

guits avatar Aug 04 '21 21:08 guits

I am working on this issue.

In Progress

Shivkumar13 avatar Aug 10 '21 19:08 Shivkumar13