-
Notifications
You must be signed in to change notification settings - Fork 2
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
Replace Docker Python SDK with Docker CLI #10
Comments
I'm not 100% sure this is a good strategy -- seems like going backwards. @heitorPB any opinion? |
Going backwards how? |
The downside of using the So, I'm with @xalelax here, not sure if using the |
I agree that in a perfect universe we'd use the Docker Python client everywhere. However, that doesn't seem to be the reality we live in. The core issue is that Docker-py is lagging behind the Docker CLI in terms of feature support, so we cannot use BuildKit from the SDK (which we need for SSH mounts for example). So we're already in a situation where we're using both: What I propose is to move entirely to using the CLI for interactions with containers. Reasons are:
For podman, all we need to do is use |
I didn't realize that until recently...
Should do the job. I liked the idea of a |
Just going to note down that another issue with swapping is error handling... it may be more ugly / less precise when we swap. https://github.com/pasteurlabs/tesseract/blob/main/tesseract/cli.py#L240-L243 |
Another issue with swapping is dealing with images. We rely on |
On this point, I have started the surgery on our cli/engine, and currently it is in a state where However, I have noticed that the docker cli version of these commands is significantly slower, so I set a timer to check: Docker CLI: Docker Py: While ps has a slowdown too, the (Don't look too hard on my draft PR...I haven't cleaned it up since i just wanted to post some initial results and concerns I have regarding the speed of the commands...) |
You can do |
Sorry for the late reply but doing that makes no difference in timing. It is still 24.6s for |
Looks like you missed a spot :) Let's discuss on your PR instead. |
Assumed to fix issues like pasteurlabs/tesseract#433 and
DOCKER_HOST
related inconsistencies. Basically, if you can use the Docker CLI you're gtg.The text was updated successfully, but these errors were encountered: