Live data from Hacker News

Piku: Allows git push deployments to your own servers

github.com

61–70 of 169 posts

Re: Piku: Allows git push deployments to your own servers

#61
post #56

15 years ago it was common to deploy web applications as live SVN repositories with a hidden path executing 'svn update' on manual http request. Not quite the 'push deploy', but that was the way apps were developed back in the days, and for some reason I still prefer that approach. Commit, test, and at one point manually nominate and deploy stable version.

Yes, when we didn’t want a build machine, we’d just build in production. Isolating production with no unauthorized binary (like Alpine) was a long path away…

Re: Piku: Allows git push deployments to your own servers

#62
post #60
post #41

Earlier quoted context omitted.

Don't they link against static libraries? How do they do that?

The runtimes are part of the Linux distribution and get upgraded along with it (and receive continuous security updates along with it), while maintaining backwards compatibility for the application code (Perl scripts or Java bytecode). Tools like needrestart will notify when a process needs to be restarted to take advantage of the update.

Ah, all your dependencies are in the language you're using? Some of mine use dependencies that are written in compiled languages.

Re: Piku: Allows git push deployments to your own servers

#63
post #62
post #60

Earlier quoted context omitted.

The runtimes are part of the Linux distribution and get upgraded along with it (and receive continuous security updates along with it), while maintaining backwards compatibility for the application code (Perl scripts or Java bytecode). Tools like needrestart will notify when a process needs to be restarted to take advantage of the update.

Ah, all your dependencies are in the language you're using? Some of mine use dependencies that are written in compiled languages.

Not necessarily, but they are part of the Linux distribution.

Re: Piku: Allows git push deployments to your own servers

#64
post #33
post #16

I think a more common use case than doing deploys by pushing to a different remote is to send git repo webhooks on PR merges to main to an API that has a deploy key and can fetch the repo itself. This afaik is missing from most PaaS tools (CapRover excluded, but it has been illegally relicensed to non-open-source). Perhaps watchtower or something could replace the functionality?

Actually, this is how I deploy my static websites: piku in lazy mode handles GitHub hooks, pulls the source and renders them out to cloud storage, then kills all workers and idles again.

Does it support deploy keys, or are your website source repos public?

Re: Piku: Allows git push deployments to your own servers

#65
post #63
post #62

Earlier quoted context omitted.

Ah, all your dependencies are in the language you're using? Some of mine use dependencies that are written in compiled languages.

Not necessarily, but they are part of the Linux distribution.

Well, I don't know about you, but my dependencies have often been built against a static library from a different version of the OS, so they wouldn't work on mine.

Re: Piku: Allows git push deployments to your own servers

#66
post #50

First time I read about piku. I have no idea why, but the feeling of `git push` to initiate a deployment like piku does always felt magical to me. There's nothing simpler than that. This is timely for me as well as I just open sourced (yesterday!) a project that is in the same space, but for Kubernetes ( https://github.com/pier-oliviert/sequencer ). All of this to say, congrats! It looks great.

It works like magic, but it's also extremely simple to DIY if you wanna learn.

If you set up a server, you can create a git repo by just doing `git init --bare`, add the setting `git config receive.denyCurrentBranch updateInstead`.

After that you can use git hooks (more specifically push-to-checkout hook), to receive uploads, compile and launch. The hook will just be a simple shell script, the most basic version could be a variant of `compile && install && systemctl restart service`.

From there you'll be able to copy the repo locally and pushing your changes will now trigger the hook you've setup.

git clone root@yourserver.com:/path/to/git/folder

Re: Piku: Allows git push deployments to your own servers

#67
post #16

I think a more common use case than doing deploys by pushing to a different remote is to send git repo webhooks on PR merges to main to an API that has a deploy key and can fetch the repo itself. This afaik is missing from most PaaS tools (CapRover excluded, but it has been illegally relicensed to non-open-source). Perhaps watchtower or something could replace the functionality?

Didnt know ... "CapRover has built in anonymous usage analytics starting v1.11" https://github.com/caprover/caprover/blob/master/TERMS_AND_C... https://github.com/caprover/caprover/issues/1852 Was looking at CapRover to see if it has REST API Looks shaddy

It’s not even open core. The solo maintainer simply relicensed the entire repo to a nonfree license without consent of the copyright holders to all the external contributions.

Re: Piku: Allows git push deployments to your own servers

#68
post #54

Earlier quoted context omitted.

Didnt know ... "CapRover has built in anonymous usage analytics starting v1.11" https://github.com/caprover/caprover/blob/master/TERMS_AND_C... https://github.com/caprover/caprover/issues/1852 Was looking at CapRover to see if it has REST API Looks shaddy

You scared me for a moment, as I've just setup a new VPS with CapRover and migrated all my projects from heroku. Doesn't look too shady for me, there's a oneliner to disable analytics, it seems enough for me.

You still have to agree to the terms and conditions of use of the nonfree application which can of course change at any time without notice. It’s a time bomb.

I’m thinking of forking it and adding all his dumb and easy table stakes features (2fa etc) that he is trying to gate as subscriptionware.

Re: Piku: Allows git push deployments to your own servers

#69
post #52

The initial commit was eight years ago?? I wish I had known about this project ~18 months ago. I was specifically looking for a way to have a Heroku-like dev experience deploying to my Raspberry Pi, and this looks like it's trying to be exactly that.

Exactly. There's a visibility problem. I've just setup a new VPS with CapRover and never found any mention of piku in the hour I've spent checking for comparisons between "Heroku-style self-hosted PaaS" dokku, CapRover, coolify, and dokploy.

We’ve been using it for a long time, yes, but doing Marketing for a 1500 LOC Python script felt a little overblown :)

Still, Chris did a public presentation on it near the beginning (video’s in the docs) and other folk did similar things, so…

Post reply on HN