nerdctl push cannot push image which pulled from a private docker registry
Maintainers usually reply within 3 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
Start by reproducing the two nerdctl push commands and compare the registry blob-mount requests, especially the /v2/.../blobs/uploads/?mount=...&from=pause request and its 400 response. Trace the push entry point and existing tests for registry blob mounting; done means an image pulled from the private registry can be pushed to the Harbor repository without the invalid repository name error.
Written by the indexing model from the issue text.
Description
- nerdctl pushed an image which had downloaded from docker hub, to a local Harbor repository, it succeed as expected
- nerdctl pushed an image which had downloaded from local docker registry, to the same Harbor repository, it failed with "400 Bad Request"
nerdctl version 2.0.4
sudo nerdctl -n k8s.io images, I have below images:
busybox:latest
192.168.140.16:5000/pause:3.10
The success image:
sudo nerdctl -n k8s.io tag busybox:latest 192.168.140.16/library/busybox-16:latest-1
sudo nerdctl -n k8s.io push 192.168.140.16/library/busybox-16:latest-1
The failed image:
sudo nerdctl -n k8s.io tag 192.168.140.16:5000/pause:3.10 192.168.140.16/library/pause-5000:3.10
sudo nerdctl -n k8s.io push 192.168.140.16/library/pause-5000:3.10
Failed logs as below:
DEBU[0000] fetch response received digest="sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669" mediatype=application/vnd.docker.image.rootfs.diff.tar.gzip response.header.connection=keep-alive response.header.content-length=133 response.header.content-type="application/json; charset=utf-8" response.header.date="Thu, 05 Jun 2025 12:24:02 GMT" response.header.server=nginx response.header.set-cookie="sid=b4d676795d6c9c9691404ad3834fb26f; Path=/; HttpOnly" response.header.x-request-id=e5aa4024-75f1-4832-992a-d36fce073f6b response.status="404 Not Found" size=316581 url="https://192.168.140.16/v2/library/pause-5000/blobs/sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669"
DEBU[0000] do request digest="sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669" mediatype=application/vnd.docker.image.rootfs.diff.tar.gzip request.header.user-agent=containerd/2.0.4+unknown request.method=POST size=316581 url="https://192.168.140.16/v2/library/pause-5000/blobs/uploads/?mount=sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669&from=pause"
DEBU[0000] fetch response received digest="sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669" mediatype=application/vnd.docker.image.rootfs.diff.tar.gzip response.header.connection=keep-alive response.header.content-length=92 response.header.content-type="application/json; charset=utf-8" response.header.date="Thu, 05 Jun 2025 12:24:02 GMT" response.header.server=nginx response.header.x-request-id=edcef50b-4867-4372-8a0a-df67ec419a9d response.status="400 Bad Request" size=316581 url="https://192.168.140.16/v2/library/pause-5000/blobs/uploads/?mount=sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669&from=pause"
DEBU[0000] unexpected response body="{"errors":[{"code":"BAD_REQUEST","message":"bad request: invalid repository name: pause"}]}\n" digest="sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669" mediatype=application/vnd.docker.image.rootfs.diff.tar.gzip resp="&{400 Bad Request 400 HTTP/1.1 1 1 map[Connection:[keep-alive] Content-Length:[92] Content-Type:[application/json; charset=utf-8] Date:[Thu, 05 Jun 2025 12:24:02 GMT] Server:[nginx] X-Request-Id:[edcef50b-4867-4372-8a0a-df67ec419a9d]] {0xc000192bc0} 92 [] false false map[] 0xc000402f00 0xc0004de000}" size=316581
DEBU[0000] fetch response received digest="sha256:873ed75102791e5b0b8a7fcd41606c92fcec98d56d05ead4ac5131650004c136" mediatype=application/vnd.docker.container.image.v1+json response.header.connection=keep-alive response.header.content-length=92 response.header.content-type="application/json; charset=utf-8" response.header.date="Thu, 05 Jun 2025 12:24:02 GMT" response.header.server=nginx response.header.x-request-id=17401ecd-77ca-4b39-9f51-ad2c055afa50 response.status="400 Bad Request" size=881 url="https://192.168.140.16/v2/library/pause-5000/blobs/uploads/?mount=sha256:873ed75102791e5b0b8a7fcd41606c92fcec98d56d05ead4ac5131650004c136&from=pause"
DEBU[0000] unexpected response body="{"errors":[{"code":"BAD_REQUEST","message":"bad request: invalid repository name: pause"}]}\n" digest="sha256:873ed75102791e5b0b8a7fcd41606c92fcec98d56d05ead4ac5131650004c136" mediatype=application/vnd.docker.container.image.v1+json resp="&{400 Bad Request 400 HTTP/1.1 1 1 map[Connection:[keep-alive] Content-Length:[92] Content-Type:[application/json; charset=utf-8] Date:[Thu, 05 Jun 2025 12:24:02 GMT] Server:[nginx] X-Request-Id:[17401ecd-77ca-4b39-9f51-ad2c055afa50]] {0xc0003302c0} 92 [] false false map[] 0xc0009bd900 0xc0009b4780}" size=881
manifest-sha256:d8c8296a995aa91d1a888d405d98f3c4a317fe2b5790b996051f7ff1184a3694: waiting |--------------------------------------|
layer-sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669: waiting |--------------------------------------|
config-sha256:873ed75102791e5b0b8a7fcd41606c92fcec98d56d05ead4ac5131650004c136: waiting |--------------------------------------|
elapsed: 0.1 s total: 0.0 B (0.0 B/s)
FATA[0000] unexpected status from POST request to https://192.168.140.16/v2/library/pause-5000/blobs/uploads/?mount=sha256:61d9e957431bdf7a34f31cbcb23fe7966ab9da5c1df35138b1e752af15b69669&from=pause: 400 Bad Request
- Dominant language
- Go
- Stars
- 10.5k
- Forks
- 853
- Avg merge
- 6d 14h
- Merged PRs (30d)
- 38
Getting set up
- Ships a Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from containerd/nerdctl
-
Test and examples: update wordpress images (to silence potential false security alerts)Possibly taken @Guurdeep claimed this 20 days ago. Openarea/ci documentation priority/low
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
containerd/nerdctl#5283 · 2 comments ·
Maintainers usually reply within 3 days
-
`nerdctl kill` shouldn't set `containerd.io/restart.explicitly-stopped` label for non-stop signalsMay be free again A pull request for this issue was closed without being merged. Openbug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
containerd/nerdctl#5171 · 3 comments ·
Maintainers usually reply within 3 days
-
area/project
Difficulty 1/5 Under an hour Newbie friendliness 25/100
containerd/nerdctl#5383 · 5 comments ·
Maintainers usually reply within 3 days
-
Restart-policy containers loop on "unable to apply apparmor profile" after reboot until the creating user logs in (OCI hook inherits the client's XDG_RUNTIME_DIR)Possibly taken @Shubhranshu153 claimed this today. Openarea/rootless bug
Difficulty 3/5 1-2 days Newbie friendliness 72/100
containerd/nerdctl#5377 · 1 assignee ·
Maintainers usually reply within 3 days
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
containerd/nerdctl#5355 ·
Maintainers usually reply within 3 days
All issues in containerd/nerdctl
Similar issues
-
P3 tech debt
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
Maintainers usually reply within 1 day
-
kind/feature needs-triage priority/unprioritized
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
NVIDIA/k8s-test-infra#1504 ·
Maintainers usually reply within 1 day
-
Area/Infrastructure Aspect/Infra Resources Type/Bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
wso2/agent-manager#2717 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
open-policy-agent/opa#9685 · 1 comment ·
Maintainers usually reply within 1 day