Hallo hackers,
since this is a very frequently asked question, i think that the video can give you a solid idea on cost on GCP. Would be great if someone is able to post a similar video for other providers (AWS would be great).
https://www.youtube.com/watch?v=N2OG1w6bGFo
Maybe we can start a very interesting an useful thread that can help lots of us.
I'm using Kubernetes (k8s) on GCP. Because Kubernetes is an open standard I can move easily to AWS, Azure or any other the numerous Kubernetes compatible providers. There are some platform specific quirks but nothing serious that would lock me in. K8S has a bit of a learning curve but having a self-healing and efficient system for deploying containers is gold.
Also using this, it also scales extremely well which is nice if it's ever needed.
Love the use of pubsub together with microservices in kubernetes
True. Though the use of pub/sub is not related to K8s. But, again, K8s adds up complexity that might not be good having when starting a project. That's my only argument.
That is correct, but they complement each other beautifully.
I've setup a couple of kubernetes clusters before, so for me it didn't take long. Although I still remember the first time, then as it really is complex and might not even be worth it unless it's something you want to try.
it's true that k8s is somewhat complex. I started with a PaaS but as costs increased it made a lot more sense to host myself using K8s.
Yeah, K8S can help you making cost control, for sure !
It's usually fairly easy to start running an application for next to nothing on one of the big cloud providers. Most services have a free tier for small usage, and they also usually include a voucher for a few hundred dollars for the first year.
The problem is what happens as your application grows. You'll suddenly see the price of the cloud hit harder and harder and, unless you design your tech stack very carefully from day 1 (which no-one does because you need to move quickly and use what you know), you'll probably be locked into the platform.
I usually start projects in Google Cloud because I know their interface, but you could easily do the same thing in AWS or another. When I start, I just use VMs - like that my code and application can (fairly) easily move between the different providers. Only when the project starts picking up do I start thinking "OK, what services do I want to start using and which is the best provider?"
Deciding which provider you want to go with is not a decision you should make on day 0.
Totally agree, though i am more a fan or AppEngine (Standard environment). But i am slowly moving to the habit of going serverless. And, of course, before getting to a point where numbers / traffic is a thing, you should already know what business strategy to adopt if things explode.
AppEngine and Google Functions (serverless) are both products by Google. If you start using them, you'll be writing your tech against Google which means your decision to use Google becomes more important.
My goal is to completely remove the question of "which provider do I go for?" from the equation. And the only way to do that is to write code that can be deployed anywhere - Google, AWS, even locally on my machine.
If you want that kind of flexibility, write your applications and wrap them in a container, such as a Docker container, and use one of the many Container-as-a-Service style offerings from all the big providers, like AWS Fargate and AppEngine Flexible.
I think that the point here is: do we want to quickly deploy and publish or we want to have a B (C,D,E,..) plan if things go in the right direction ?
It's true that being agnostic about the providers is a great thing, but for an indiehacker, which might NOT have the skills/knowledge/experience to achieve this, what is the cost ?
Plus, just think about the simplest thing here, a DB. With all the great tools that are around as a service, would you really go and "buy" all the devops problems a db deployment/management takes ? Why don't take advantage of DynamoDB, Google Cloud Datastore/Firestore, etc ?
For example, if i can create a React app, use firebase auth mechanism, and use firestore/datastore as storage just by using a bunch of restful apis and providing access keys from the outside it would be madness to start playing with containers etc: i would just need to create ONE js file and the app would be ready.
Of course this is not written in the stone, it's only my opinion, and there is a trillion scenarios this is not going to work properly, but ... are we talking about quick market tests ? This way of doing things is great.
I think that this approach is the one that gives you the chance to really focus on business logic, forgetting about aspects that are not trivial in terms of operations.
But probably we're derailing, i just wanted to give a price argument to the audience that very often pops up asking about "what tech stack should i choose?". Just bits of info on something that is critical, costs. And would be great to hear any other info about other providers.
The choice will always be ours, and cannot be disjointed by personal experience and/or fears.
I actually think you should lock your self in. Why not? After all, you're interested in making money and launching a product when it's just an idea. Who cares if you're locked in for your MVP that's 5,000 lines of code and mostly integrations and triggers to external services: just rewrite it (which is unlikely required anyway.)
People overstate "vendor lock-in" and conveniently forget about good programming practices that prevent the lock in at a code level, like interfaces and generics.
Plus, if you are a one-man band running software, probably you need a tech partner, and so it might also be convenient.
I totally agree. Infact all my stuff is nicely locked-in in Google Cloud Platform (and some on AWS, but minor things). If i'd reach the point where i need to save money unlocking myself i'd for sure have resources to face it ;-)
It'll likely be more expensive to "unlock" your self. Man hours are expensive. Google's time is cheap because they're charging you a fraction of their $1,000/hour fee (they've spread it across thousands of customers.)
Exactly - great approach.