NHacker Next
login
▲Show HN: Pooshit – Sync local code to remote Docker containers
51 points by marktolson 8 hours ago | 42 comments
Loading comments...
sippeangelo 7 hours ago [-]
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
aitchnyu 20 minutes ago [-]
Is there a single line Podman alternative?
parhamn 2 hours ago [-]
What!?!? This is a thing? How did I not know about this. Thanks for the share!
zsimjee 7 hours ago [-]
To me, it looks like this new project is aimed more at being able to develop remotely and share your localhost:3000 env instead of getting a real production box up. Bidi sync etc... hints at that, it's like having a 2-interface dev env.
sippeangelo 7 hours ago [-]
I don't see that at all?
robertlagrant 7 hours ago [-]
Wow - never seen that before.
marktolson 6 hours ago [-]
Probably pretty similar except you get to just write "pooshit" instead.
scottydelta 4 hours ago [-]
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.

marktolson 4 hours ago [-]
Not sure if you read the description but I clearly stated that I wanted no middleman, so I'm not sure how this solves my use case. Also not sure how it requires the same amount of time, and 'manual intervention every time'? You provision a remote server, install docker then update the local config file and it's done. One line deployments everytime. And why would I update the code inside the container when you need a build process to install dependencies? If you want to update code while the app is running then restart, then docker is not the right solution.

Additionally there are a million different and better ways to deploy services, this suits the use case I described.

coded_monkey 2 hours ago [-]
There is nothing “industry way” about letting CI automatically deploy your production environment.
bilekas 6 hours ago [-]
Can't wait to try and get this greenlit at work.
infogulch 5 hours ago [-]
My grandma laughed at this one.
marktolson 5 hours ago [-]
Better off trying to get it brownlit.
ElCapitanMarkla 8 hours ago [-]
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.
eightnoneone 7 hours ago [-]
How does this compare to https://www.devspace.sh/ ?
marktolson 6 hours ago [-]
It's not based on k8s, it's just pushing your local app to a server and spinning up a conainer with one CLI call.
gregjw 5 hours ago [-]
what a name! fun conversations ahead for people that want to utilise it at work!
_def 7 hours ago [-]
I don't really understand the use case and wonder if containers are the right tool here at all.
marktolson 6 hours ago [-]
Here is my main use case. I have lightweight services that I need to update and deploy regularly (until I movee to K8s or a proper production env). Using pooshit, I can push my entire local dev folder to a remote server then destroy the old image, rebuild the new image and spin up a new container with one call. Your config file contains your remote config. You need nothing in between you and your remote server and it only relies on SSH and docker, nothing else, no middleman, repos, and no deployment containers running on your VM.
wolttam 5 hours ago [-]
`docker context`?
lagniappe 8 hours ago [-]
no middlemane i like it
WastedCucumber 8 hours ago [-]
Dumb question, out of real curiosity - is the double fecal pun deliberate?
robertlagrant 7 hours ago [-]
I can't wait for version number 2 to drop
upghost 4 hours ago [-]
I am actually surprised how well it runs, given how solid it is
4 hours ago [-]
badc0ffee 3 hours ago [-]
The joke is a deuce.
electroglyph 7 hours ago [-]
shitty joke if you ask me =)
65 3 hours ago [-]
It's actually a triple fecal pun! Push it... poo... shit.
CBLT 8 hours ago [-]
Line 1 of the readme has a poop emoji
marktolson 6 hours ago [-]
Yes.
mhuffman 7 hours ago [-]
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.
another-dave 7 hours ago [-]
I can't remember what the package was, but when I was working for "large bank", one of the npm dependencies we wanted to use had a licence file that just said 'Do whatever the fuck you want'.

Legal came back saying that it was "highly unorthodox, but approved for use"

catlifeonmars 4 hours ago [-]
That’s amazing. I’d really like to steal that, but not being a lawyer, I’m not sure how viable it is as an actual license.
dijksterhuis 3 hours ago [-]
FSF has approved it, OSI has not. Make of that what you will. https://en.wikipedia.org/wiki/WTFPL

Notes from OSI rejection board meeting

> It's no different from dedication to the public domain.

-- https://en.wikipedia.org/wiki/WTFPL#cite_note-osi-2

spacebanana7 7 hours ago [-]
I believe people chose to pay Adobe subscriptions simply to avoid explaining the acronym for the GNU Image Manipulation Program in meetings.
thot_experiment 2 hours ago [-]
I'm going to have to challenge you on this one. I'm not great lover of Photoshop, and GIMP does have an unfortunate name, but it is an alternative to Photoshop in the same way Gentoo is an alternative to Mac OS, you're not wrong but...
chillfox 6 hours ago [-]
I have never worked at or heard of a company caring about the names of software, at most it's been a bit of a chuckle. Best guess is being concerned about software names is a super conservative culture thing.
mhuffman 1 hours ago [-]
I do believe you, but be honest, both of us could come up with an easy half-dozen names for software that if spoken out loud at work or triggered a filter on the network at the office would have someone explaining to HR what the hell is going on.
manquer 5 hours ago [-]
Perhaps not directly in a review.

Names can be troublesome though, badly named products get caught in spam filters, or blocked in some firewall blacklist.

catlifeonmars 4 hours ago [-]
The cockroachDB thing, was that intentional or just incidental?
mouse_ 8 hours ago [-]
good post
fny 6 hours ago [-]
This is a steaming pile of SFTP. Why not use rsync or wrap it if you must?

For anyone who's interested in proper bidirectional sync check out Mutagen.[0]

[0]: https://mutagen.io/documentation/synchronization/

marktolson 6 hours ago [-]
Because I don't want to do this: https://mutagen.io/documentation/introduction/getting-starte...