d11wtq / dockerpty

Pseudo-tty handler for docker Python client
https://github.com/d11wtq/dockerpty
Apache License 2.0
156 stars 62 forks source link

SCP/SFTP-ing a file into a container over SSH is now possible #82

Open willnx opened 5 years ago

willnx commented 5 years ago

I noticed the Apache2 license on the code, so here are the changes I'm making for my needs.

With these changes, it's possible for someone to leverage dockerpty over an SSH connection and have SCP/SFTP work as expected. It would be up to the calling application to manage cleaning up and teardown of the container, but at least dockerpty wont spin indefinitely when SCP/SFTP triggers an EOF on stdin.

I tested this functionality when using the dockerpty.start functionality.

Feel free to take this update, or just close the PR. Thanks for doing 99% of the work and making this awesome library! 😄

willnx commented 5 years ago

Just to be clear, my referenced issue is calling my application's support of SCP "crappy". I think dockerpty is great, and am super happy it exist! Thanks again for making this great library!