News for hackers. Stuff that matters.
Re:Ask HN: Infra people in small companies, what does your i... by colomofo on Saturday November 04, 2023 @11:11AM (#38141746)
I've built infra for a lot of different orgs over a long period of time. My recommendation is that unless (and until) you're building for scale, you Keep It Simple, Stupid (KISS).

Use an IaC system (Terraform, Pulumi, etc) to manage everything from Day 1:

1. Use a major cloud provider (AWS or GCP, probably)

2. Get a managed HTTP load balancer (ELB, ALB, whatever)

3. Run your app on 3+ containers behind it (running on bare VMs, K8S, whatever you prefer)

4. Set up a managed database cluster with Postgres or MySQL

5. Run 2 machines (for redundancy) for asynchronous jobs (using cron, a message bus, or DIY)

6. Store any large files in cloud storage and put them behind a CDN

That's all 99% of companies will ever need to do. These are all old technologies that Just Work.

Re:Ask HN: Infra people in small companies, what does your i... by skor on Saturday November 04, 2023 @11:51AM (#38142162)
any reliable managed database cluster suggestions? I’m looking for mariadb or mysql, former preferred thanks
Re:Ask HN: Infra people in small companies, what does your i... by colomofo on Saturday November 04, 2023 @12:08PM (#38142327)
Cloud SQL from GCP or RDS from AWS should both work just fine. They're just about the only companies I trust managed databases from.
Re:Ask HN: Infra people in small companies, what does your i... by skor on Saturday November 04, 2023 @12:15PM (#38142416)
thanks
Re:Ask HN: Infra people in small companies, what does your i... by tkiolp4 on Saturday November 04, 2023 @12:47PM (#38142719)
How does a deployment look like in that setup?
Re:Ask HN: Infra people in small companies, what does your i... by colomofo on Saturday November 04, 2023 @01:31PM (#38143229)
It depends how you deploy the app containers.

If you use a container orchestration service (ECS, GKE) then you use that system to upgrade container image with new app versions.

If you use autoscaling groups / managed instance groups, then you use that to replace VMs with new ones running containers with the new app image.

Using rolling updates, the load balancer drains connections to a container and then it is replaced.

Ideally this is done using your IaC system. So a deployment just involves changing the container image (app version) and applying the update.

Re:Ask HN: Infra people in small companies, what does your i... by mrngilles on Saturday November 04, 2023 @01:01PM (#38142871)
I would like to have some insights about this as well
Re:Ask HN: Infra people in small companies, what does your i... by atmosx on Saturday November 04, 2023 @03:59PM (#38144573)
I've worked with quite a few small teams in the past, part time. Never had a fleet as small as 2 VMs, more like 20-120. That's a good summary. Only thing missing that comes up always is the CI/CD workflow. I've found bitbucket's CD surprisingly _good_ once you follow the enforced pattern, especially for small teams who don't want to spent too much on release technicalities.

Then there's more nuanced things that most teams will miss early on without someone pointing the problem and the solution e.g. decouple configuration from the app, design stateless apps (e.g. 12 factor app), use secrets management easily (e.g. dynamoDB based solutions like credstash are dirt cheap, AWS secrets is okay-ish), used managed DBs (RDS is the most common choice) and more.

Re:Ask HN: Infra people in small companies, what does your i... by aprdm on Sunday November 05, 2023 @12:02AM (#38148032)
really ? Wow.. I've never had 120 VMs to manage in any org I was part of, and have worked on fortune 500 companies !

I have provided infrastructure-as-a-service for many many baremetal/VMS/containers, but then I wasn't managing them (e.g: it was many small team's infra, not a small team of 10 people using 20-120 VMs as per OP)

Re:Ask HN: Infra people in small companies, what does your i... by atmosx on Sunday November 05, 2023 @03:10AM (#38149264)
That didn’t come out well - by VMs I mean EKS or Swarm nodes not VMs in term of “pet” not “cattle” :-)

The number of nodes was used to run a monolith. Same deployments and all, wasn’t as complicated as it might sound (terraform to manage infra, few custom apps to talk to external APIs, etc)

These were definitely not 500 fortune companies but AFAIK all of them had some cash flow or were acquired by behemoths.

Re:Ask HN: Infra people in small companies, what does your i... by nip on Sunday November 05, 2023 @01:41AM (#38148615)
Excellent comment and suggestion!

Very refreshing to read in this day and age where it’s not uncommon to have more micro services than paying customers.