-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
docker-java push fails against the podman service #8713
Comments
I debugged the issue a bit further. The problem is that the "podman push" REST call does not return any data, expect a line feed character, while docker returns a stream of JSON status object like:
An older version of the docker REST API shows the format: https://docs.docker.com/engine/api/v1.24/
In the latest version I can however not see that part: https://docs.docker.com/engine/api/v1.41/ Anyhow, the difference in the returned data format is breaking the clients and thus the Docker REST API support of Podman. |
The HTTP API entry point for the push seems to be here: https://github.com/containers/podman/blob/master/pkg/api/handlers/compat/images_push.go#L18
To implement this in a compatible way a problem should be on what point the JSON objects need to be created. Logical seems to do this on the HTTP side but then a simple Writer as the progress reporting interface does not work. Figuring out on the otherside that this is about JSON seems a bit ugly but would allow the HTTP side to just read out the progress lines and send them blindly to the caller. A small thing that looks odd to me is: https://github.com/containers/podman/blob/master/pkg/api/handlers/compat/images_push.go#L66 |
@jwhonce PTAL |
Hi, any chance somebody looked into this yet? This prevents us from switching from docker to podman. |
@Hendrik-H Sorry I don't believe anyone has looked at it. |
@Hendrik-H Can you share your gradle script? |
Hi @jwhonce , here is a sample
For the test I started podman as a docker replacement using:
I also started a local docker registry using:
Lastly I edited The podman log shows that the push was actually successful but as stated the Java client that is used under the covers fails as the REST call to podman does not return any status JSON but just a 200. |
The same problem is described in issue #7857, just for pull endpoint. Can be reproduced with: |
A friendly reminder that this issue had no activity for 30 days. |
@mlegenovic Does this issue still exists? I thought we had fixed all of the Java issues. |
@rhatdan I forgot this one :-( too many things in my head. I had it locally on my PC, but forgot to create PR. |
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
Steps to reproduce the issue:
start podman as a system service:
podman system service tcp:0.0.0.0:2375 --timo=0
wrote a gradle build script that uses https://github.com/bmuschko/gradle-docker-plugin to build docker image and to push it
the build fails during the push
Describe the results you received:
The push fails with:
Describe the results you expected:
The push to work as podman's API implementation should be compatible to that of docker.
Additional information you deem important (e.g. issue happens only occasionally):
Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide?
Yes
Additional environment details (AWS, VirtualBox, physical, etc.):
A pod in an OpenShift setup.
The text was updated successfully, but these errors were encountered: