I am curious how people in the community host there projects in various different stages of their projects
What if you are just starting out?
What if you have a nice pipeline of users signing up?
What if you are hitting scale?
I ask this because in the past a few friends and I were working on a sideproject and WASTED cycles setting GitOps with AWS Beanstalk, a Staging environment etc with no users. I don't think we needed anything so heavy so I go fairly simple now. Wonder what others do!
Whenever it comes to ramping up a project, I tend to spin up a DigitalOcean droplet (super cheap) for the backend, then host the frontend on Vercel.
My go-to stack right now is SvelteKit + Pocketbase, so getting ramped up between the two is super fast (~5 minutes) and it's very performant starting out.
Are you still sticking to DigitalOcean? What Droplets you usually use? My projects are SvelteKit + Pocketbase too
PocketBase looks so cool! I have to check it out! Seems like something that helps you just add value and not worry about a lot of boilerplate,
VPS.
You are not Uber, and most likely will never be. Most people overengineer their infrastructure for the sake of overengineering and dreaming to have 1m users per second. Keep it simple, and CHEAP. Use a VPS
If you are starting, then the use of Back4app would be a free-to-start and economical solution for you. This simple-to-use CSP lets you deploy your projects using a Git repository without any downtime. Similarly, with flexible horizontal and vertical scaling, it also overcomes your concerns regarding scaling.
You can also get more details from here https://www.back4app.com/web-deployment-platform. Realtime DB management, user authentication, push notifications, free-tier plans, and support for technologies like Docker, Redis, NodeJS and PostgreSQL are key traits of this platform.
On the other hand, AWS Amplify and Firebase could also be on your list with seamless hosting and backend functionalities.
I keep it simple :)
I'm using Vercel for frontend and AWS for backend
Agree with you Gyani! No need
Just starting out as indie hacker, but have experience on hosting large projects.
AWS for both, it is very convenient.
I am currently hosting 2 projects with CI/CD, auth, frontend, db, secrets etc. on two aws accounts (dev and prod), i pay like 4-5 bucks per month.
Just curious, what do you use for CI/CD? Do you think a Jenkins deployed in a VPS or something like that would be a good idea? (I'm starting also as IH btw)
I use AWS Codepipeline. I pay either 0 or 1$ for codepipeline per month (because I have two (one for dev and one for prod), you have free tier for one only), and that's it. My CI/CD (I have 600+ commits by now) costs me basically nothing.
Oh cool, I'll consider something like that when I start deploying things, thanks for sharing!
different stages of project hosting within the community and the optimal approaches Like,
If you're new to services like AWS or GCP and you need an uncomplicated solution, I suggest checking out Render. Render provides everything you need to host your server, static website, PostgreSQL, and Redis. The best part is that all of these services have a free tier. Previously, I used DigitalOcean, where I had to pay for every service, even if I only needed it for development or staging environments.
I’m using AWS free-tier serverless resources: Lambda, DynamoDB, Cognito, CloudFront, etc. It’s free for thousands of active users, scales well, and I don’t need to manage servers, i.e. virtually no downtime. However, it’s harder to configure, but I’m a Devops.
Would you like to hear more about such setup?
A really cheap (and I mean basically free) setup can be done with AWS and Terraform
And thats it. Terraform ensures that you can easily create re-producible environments. The AWS Lambda FastAPI + Mangum combo essentially means you can run an entire FastAPI instance in a Lambda function, which makes the BE basically free until you hit scale. Cloudfront coupled with an S3 bucket is also free until you hit serious traffic.
The above basically scales to infinity (or at least until you run out of lambda invocations) and its dirt cheap
I find that whether you're just starting out or if you have a nice pipeline of users, Vercel & Netlify are good ways to start. Once you hit scale & the pricing for these is less manageable, I usually rely on AWS. I've used SST before and I find it makes working with infrastructure a lot more manageable.
Hey! What you described here is exactly why we created ArchFormation. It builds a cloud infrastructure with DevOps best practices in minutes. We are currently offering a free beta and would greatly appreciate your feedback!
Generally I try to stick with the simplest thing first. The simpler it is, the faster I can build it and get it in the hands of users to see if it's worth exploring further. Modern computers are FAST so you largely won't need to worry about scale until you're making enough money to get a bigger server.
I like to use PaaS like GCP Cloud Run or Digital Ocean App Platform cause it takes care of deployments for me.
You can set up a server for about $5 / m and a database for $12 / m and that'll handle your first few hundred users easily.
Here's how I host my site for less than $1 / m on GCP Cloud Run - https://hamy.xyz/labs/2024-01_how-i-host-site
for my first very small side-projects that only included a static frontend I used Vercel or surge/.sh
now I rent a VPS for 5€ a month, set up Caddy as a file server or reverse proxy and wrote a small script for uploading assets from Github actions via SFTP
With one domain I can host as many side-projects as I want - each under a different subdomain!
I have no experience with scaling yet..
I started using Laravel again for the first time since college. Deploy to Laravel Forge quickly and easily.
I made https://byebyefitness.com with Laravel, every page is just blade templates with very little JS at all.
I'm working on a more interactive/data intensive app and Laravel Breeze is literally a breeze. It is so much easier than creating a react app, API, worrying about coordinating redis, memcached, app server, database etc.
For mobile apps, API Gateway + AWS Lambda for the API.
Digital Ocean has cheaper databases than RDS and it is easier to use.
I found the balance between simplicity & reliability on Cloudflare. They have a generous free plan and are full-stack ready since 2021 – which got tested with time. For the database side, I'm using Planetscale.
And I can't agree more with your statement. At the early stage, we must strive for simplicity and not worry about the infrastructure.
I hope you get an optimal stack for the next project.
Thank you! I haven't interacted much with cloudflare workers but I do like the cloudflare pages offering; I'll checkout how far I can get with workers.
I haven't used Workers as well. I'm using Svelte with SvelteKit, so what I know is making the server's logic or even API routes on it. Those will translate to functions on Cloudflare.
Good luck, @gyani!
Frontend: AWS Amplify
Backend: AWS Amplify or AWS Elastic Beanstalk
I am wondering how you got into the AWS line of products - was it for the credits?
I use Vercel and just recently crossed the threshold for the free tier, so now I'm paying $20 per month!
Not sure how long Vercel's pricing will remain sustainable, I might have to switch to Cloudflare or AWS at some point
Using Github for version control with Github Actions for deploying the web in Vercel is pretty much dead simple.
I think vercel could be a good choice for projects using modern frameworks like Next.js…
It's known for its ease of use, speed, and efficiency in deploying static sites and serverless functions. Additionally, its free tier is often more than sufficient for personal projects and small-scale applications.
I agree, Vercel is very easy to use and it works well.
My projects are websites so i put everything on GitHub Pages. I have like six sites for $5/mo
Vercel for frontend and flyio for backend
I use scripts from my book Deployment from Scratch and Kamal. I wrote down how to use Kamal for a simple single server deployment. And I'll include even more harden configuration to my SaaS template so everyone can start in no time. I self host database too for cost savings.
Host projects on cloud platforms (AWS, Azure, GCP), PaaS (Heroku, Firebase), dedicated servers (OVH, DigitalOcean), or serverless (Lambda, Azure Functions). Consider project needs, scalability, and cost. See more…
It depends on what you're building. I have split it into diff providers doing different things.
I use Cloudflare Pages to host marketing page, static assets that customers are loading, and whole app. (All that is free)
I use AWS EC2 to host API that APP uses and to handle cronjobs and it also works as a queue consumer from Cloudflare queues.
AWS RDS for MySQL
AWS SES (for email service)
Mailerlite (for marketing communication)
AWS resources you can use free up to 1 year, then you need to subscribe to some service where you can get 5k USD credits for another 2 years, and if you're lucky you can find more and extend to another 2 years. My suggestion would be going by tiers. 1k USD, 5k USD and then 10k USD. Up to 100k, start as low as possible as the next one has to be bigger.
Auth0 for authentication between APP and API (free)
Cloudflare workers to handle super high demand of public api requests combined with cloudflare images and cache API to reduce the costs. Before go live you can use free tier from Cloudflare - it is very generous.
NewRelic for monitoring (free)
So all in all you can basically run free of charge for very long time before you go live. After you go live and start gaining traffic, you will need to beef up a bit with better WAF, servers, load balancing, etc.
Running free will also give you an idea of potential costs later on. For me AWS is very tricky and somewhat hard to predict, it looks good until you have high traffic. So make sure to build your application which would allow you to switch cloud providers. Like digitalocean or go serverless.
Hi Gyani,
My go to is Firebase. It gives me a lot functionalities out of the box to host both web server, app server, cache and database. If you make your projects in JS i.e. reactjs, nodejs + expressjs, then it is a no brainer.
However, for my new project VascoVisa, I am using GCP for app server as it is build using FAST (python3) and firebase does not supports it. However, other components are in firebase
Flask for both backend and frontend, push code to github, pull in a tmux session where you have multiple ttys(one to run the flask server and tail logs, one for database debugging, one for pulling code and misc), run a local database in the same server(take periodic backups to S3).
I'm running 3 servers like the above setup in a single AWS instance, which came with my $1000 free credits. And, I would roughly spend like $10-50 per month I guess, not sure but far less.
P.S: All this ofcourse depends on the load of the computation that you perform. In my case, all are not so compute heavy and data oriented products
https://raspberryrack.com/
https://t.me/PuffBuddyBot/
https://breakingpiracy.com/
BuyVM $2 / server x 2 = $4 / mo
Cloudflare DNS load balancing $5 / mo
GitHub Actions to build a single binary server (Rust backend) $0
SendGrid for EMail $0 free plan
Postgres pgsclusters $7 / month for a managed DB
Domain name registration all-inkl (very cheap German hosting company with 3 free domain names) $5 / mo
Finom Bank Account (free plan) + PayPal = $0
= $26 / month, I have a very long runway until I'd need to be profitable
I tried Kubernetes + Docker, but that would cost me $50 / month ($700 / year vs $312 / year) and it's not worth the hassle at this stage. So I make a single-binary server that just takes a secret config file URL on startup to configure DB connections, etc. It's very unprofessional but very cheap + works just as well as kubernetes as I only push updates infrequently.
On the server I just do
curl github/releases/my-server-binary && my-server
and then thanks to DNS load balancing the site doesn't go down while I push updates. Since the backend is in Rust it has virtually no performance issues.I host on netjet
nice
Keep development, testing, staging, and production environments separate.
Use tools like Terraform or AWS CloudFormation to define and manage infrastructure.
Set up CI/CD pipelines for automated testing and deployment.
Employ monitoring tools like Prometheus, Grafana, or ELK stack to identify issues early and improve performance.
Aren't testing and staging the same? Isn't one supposed to fix bugs and/or implement features locally, on development environment and then, after merging a PR into a support branch, it goes on staging where the tests happen, which is meant to mimic prod env, same config etc, except not real data? Why both testing and staging just curious how others are using it.
Not normally, testing would have higher churn and more smaller deployments to it. However staging is a place to only deploy releases due to go out. It can also be used to confirm and debug issues found in prod if needed as it should match in data and release version.
Data is important to have the same in stage as it can be the reason for bugs and inefficiencies are found only in prod.
Also you can use staging to test scenarios as close to production as possible without breaking production, show demos or give training sessions to the production operators in close-to real life scenarios, safely debug problems on customer data related issues etc. Staging is like a safe production. Should have the same 3rd party applications available (and not mocked ones) and similar type of resources (ie RedHat if that is what runs production and not Ubuntu as on dev's laptops) and similar hardware (but less powerful to cut costs).
Just use firebase hosting, it is free for upto 10,000 concurrent users.
Esto funciona para backend y frontend ?
backend
I've tried a few different ways of hosting some of my projects. Vercel, Netlify, I even dabbled with AWS Amplify.
For my project TinySurvey, I settled on Cloudflare Pages/Workers using Supabase to host the database and handle the auth.
There were a few reasons I chose Cloudflare over Vercel/AWS:
It's been great so far for the early stage of my project!