Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does skopeo support local docker registry? #459

Closed
gouyang opened this issue Nov 23, 2017 · 10 comments
Closed

Does skopeo support local docker registry? #459

gouyang opened this issue Nov 23, 2017 · 10 comments

Comments

@gouyang
Copy link

gouyang commented Nov 23, 2017

[root@localhost ~]# docker tag docker.io/busybox localhost:5000/skopeo/busybox
[root@localhost ~]# docker push localhost:5000/skopeo/busybox
The push refers to a repository [localhost:5000/skopeo/busybox]
0271b8eebde3: Pushed 
latest: digest: sha256:91ef6c1c52b166be02645b8efee30d1ee65362024f7da41c404681561734c465 size: 527

[root@localhost ~]# skopeo copy docker-daemon:docker.io/busybox:latest docker://localhost:5000/skopeo/busybox
Getting image source signatures
FATA[0000] Error checking for blob sha256:0271b8eebde3fa9a6126b1f2335e170f902731ab4942f9f1914e77016540c7bb at destination: pinging docker registry returned: Get https://localhost:5000/v2/: http: server gave HTTP response to HTTPS client 
@gouyang gouyang changed the title Does skopeo support local docker registry Does skopeo support local docker registry? Nov 23, 2017
@giuseppe
Copy link
Member

do you need --dest-tls-verify=false?

@mtrmac
Copy link
Collaborator

mtrmac commented Nov 25, 2017

Yes, please verify whether --dest-tls-verify=false works.

It might be the right think for skopeo, or c/image, to use c/image/pkg/sysregistries by default—but first we need to know that this is indeed the difference.

@gouyang
Copy link
Author

gouyang commented Nov 27, 2017

# skopeo copy --dest-tls-verify=false docker-daemon:docker.io/busybox:latest docker://localhost:5000/skopeo/busybox
Getting image source signatures
Copying blob sha256:0271b8eebde3fa9a6126b1f2335e170f902731ab4942f9f1914e77016540c7bb
 1.28 MB / 1.28 MB [========================================================] 0s
Copying config sha256:6ad733544a6317992a6fac4eb19fe1df577d4dec7529efec28a5bd0edad0fd30
 1.46 KB / 1.46 KB [========================================================] 0s
Writing manifest to image destination
Storing signatures

It works.

@mtrmac
Copy link
Collaborator

mtrmac commented Nov 28, 2017

@baude Do you think containers/image should automatically use c/image/pkg/sysregistries to configure insecure registries?

@duritong
Copy link

I think this would make sense and then it could still be overwritten by cli-flags.

@akram
Copy link

akram commented Mar 21, 2019

The answer 👍
skopeo copy --dest-tls-verify=false docker-daemon:docker.io/busybox:latest docker://localhost:5000/skopeo/busybox

works great, maybe you can close the issue

@gouyang gouyang closed this as completed Mar 21, 2019
@HectorB-2020
Copy link

Hello @giuseppe and @mtrmac!
I guess this command line parameter has been changed to --tls-verify=false.
At least it aided me in overcoming the well-known registry error 'http: server gave HTTP response to HTTPS client' while dealing with local registry:2.

At the same time the help page is not obvious

--tls-verify          require HTTPS and verify certificates when talking to the container registry or daemon

Probably it makes sense to add something (default: true).
What would you say?

@HectorB-2020
Copy link

My bad, I beg you pardon. Different commands have different parameters indeed.
It is --tls-verify for inspect but --src-tls-verify and --dest-tls-verify for copy.
Still in my view it makes sense to add something like (default: true) to all the help pages.

@mtrmac
Copy link
Collaborator

mtrmac commented Feb 13, 2023

@HectorB-2020 The default is not actually specifically true, the default depends on registries.conf settings from that registry. The man page does say that (somewhat…); it doesn’t fit well into --help.

@HectorB-2020
Copy link

I see, thanks very much!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants