Live data from Hacker News

Ask HN: How do you cost-efficiently host your small personal projects?

news.ycombinator.com

1–10 of 22 posts

Ask HN: How do you cost-efficiently host your small personal projects?

#1
As the title says, how do you all host your small personal projects with an eye towards cost? I've ruled out hosting them locally in my home lab.

I'm putting together a small personal project related to one of my hobbies, basically a tiny web app. It will have a small Postgres DB, a basic Flask API, and then eventually a TypeScript frontend. The MVP is essentially creating a query-able backend for contest results, though eventually I'd like to expand it to a whole management platform for these contests. The events happen infrequently (~3 times a year at most) so the data grows in (small) bursts and is otherwise static. At this point it's entirely text and number data as its currently managed through spreadsheets.

For deployment, I'm considering:

* AWS RDS + EC2 (or the GCP equivalent) for the db + API * Fly.io (or another provider in this space (Heroku?)) because deploying at the edge is appealing and their DB pricing seems reasonable * Fully manual via VPS / dedi hosts like OVH/Vultr/Scaleway/etc

AWS/GCP is appealing because of familiarity through work and it offloads having to manage the databases myself and the data centers are closer to our user base. EC2+RDS works out to ~$20/mo for EC2 (t4g.small) + ~$25 for RDS (db.t4g.micro), GCP is about half that (~$25) for an e2-small and db-f1-micro.

Fly.io is similarly appealing with the benefit of edge deployments, not that my application is particularly latency sensitive. Fly.io would be between ~$7 (free tier compute + basic postgres) and ~$20. Heroku would be between free and $16/mo (for the $7 hobby dyno and $9 hobby basic psql)

OVH et. al are appealing on a cost basis, but feel like they would require a lot more work to ensure similar reliability to the other options. Kimsufi would be between $10 - $40/mo depending on the data center location (Canada or France), Vultr (VPS) would be $10-15/mo, Scaleway Dev (VPS) instances would be $10-$20/mo, Hetzner (VPS) would be $10-$15 (though the downside being their data centers are in Germany and Finland while the majority of our users are in the USA). Specs seem better for the money for these but at the cost of having to manage all of the infrastructure myself.

Re: Ask HN: How do you cost-efficiently host your small personal projects?

#4
post #3

> I've ruled out hosting them locally in my home lab. Then you've also ruled out "cost-efficiently host[ing]" them as well. The most cost efficient method is using the internet connection you already have and are already paying for to also host them.

Read it as "cost-efficiently externally hosting" then I guess. For a PoC I might host locally just to show it off to others, but I wouldn't want to deploy it there long-term, mostly since I'm not physically near said lab for several months at a time so if things went down it'd be a drag.

Re: Ask HN: How do you cost-efficiently host your small personal projects?

#5
post #2

Dokku running on AWS light sail or DigitalOcean

Interesting, I hadn't heard of Dokku before (looks similar to Flynn and Deis (looked into those back in 2016 before k8s was the de facto choice) but still actively developed) and I overlooked Lightsail. I'll have to price out DigitalOcean as well, I used them for a project in school because they gave out free credits and the experience was good iirc.

Re: Ask HN: How do you cost-efficiently host your small personal projects?

#7
Can you just use a Linode? It’s $5/month. I bought a Linode VM and set up a server and database on it.

Main drawback is efficiency, idk how fast a linode works once you have users. But once you have users if you can make money off them, you can migrate to AWS.

Re: Ask HN: How do you cost-efficiently host your small personal projects?

#8
Why don't you use GAE or Cloud run on GCP? They have a big enough free tier that you won't have to pay even up to thousand or so users.

The only cost would be storage, if you're going to use SQL. But then again cheap enough.

I'd suggest porting to key/value pair DBs like mongo or firestore.

Re: Ask HN: How do you cost-efficiently host your small personal projects?

#10
post #9

CloudRun, Lambda, Azure Functions or similar. It’s million requests for like $0.05 or something trivial. By the sounds of it you probably could stay well under the free tiers offered. CloudRun is just setting up a docker image properly..

How does google cloud cloudrun compare to azure app service? I am asking as I ran a 70$ bill just deploying my application to azure app service, approx 10-20 times or so.
Post reply on HN