Show HN: Pooshit – Sync local code to remote Docker containers

55 points by marktolson ↗ HN
Pronounced Push-It....

I'm a lazy developer for the most part, so this is for people like me. Sometimes I just want my local code running in live remote containers quickly, without building images and syncing to cloud docker repos or setting up git workflows or any of the other draining ways to get your code running remotely.

With pooshit (and a simple config file), you can simply push your local dev files to a remote folder on a VM then automatically remove relevant running containers, then build and run an updated container with one command line call.

It works well with reverse proxies like nginx or caddy as you can specify the docker run arguments in the pooshit_config files.

https://github.com/marktolson/pooshit

15 comments

[ 3.3 ms ] story [ 38.7 ms ] thread
Dumb question, out of real curiosity - is the double fecal pun deliberate?
I had a similar script a few years ago when I refused to give up my aging Macbook Air and built a server to host my dev env. I had an rsync command that would sync the differences from my local machine up to the remote box. It was surprisingly quick considering the size of the projects.
Neat project, but what does this do differently than docker compose with the --host flag? https://docs.docker.com/reference/cli/docker/#host

It uploads your whole local docker context, source code and all, builds the image on the remote server and up's the container(s) all with a single command. I use this all the time when deploying simple services to avoid all of the complexity of registries etc.

    docker -H ssh://remote compose up -d
This random comment just saved me several hours of work. I had no idea I could pass in ssh URLs to -H. It turns out that this also works with the docker python library!
Useful project. Name that no reasonable company would allow IT department to use. 10 out of 10! It worked for CockroachDB. I hope it turns into a unicorn and I'm not joking about that.
I don't really understand the use case and wonder if containers are the right tool here at all.
Can't wait to try and get this greenlit at work.
what a name! fun conversations ahead for people that want to utilise it at work!
I understand what you are trying to do but you should checkout dokploy or coolify.

You push to github, github action builds it and hits dokploy webhook and it pulls your github code and build and deploy on that server.

This is more reliable and industry way. What you are doing requires same amount of time to deploy and requires manual intervention every time.

For once i thought you were moving code to server and then you just restarted container and it worked without having to build. I have done it in the past due to some unique requirements where dependencies are in docker image and code is copied from local to server and docker image took code from server on start.

I have to say, the name is a great touch.