The mythical ChatOps in action

Imagine having multiple services running, each has its own logs. Most people don’t read them, and they shouldn’t, because services emit a lot of logs! But we need them, because it’s the only way to diagnose and troubleshoot system errors. But you might say “my service is not a system! It’s only doing tiny stuff!” Gotta break it to you, your small part is a piece in a large system networks stitched together! So your seemingly-tiny service is also important! ...

April 18, 2023 · 3 min · Karn Wong

Bare metal works, until it doesn't. Hello, cloud.

Background Ever wonder how websites (and everything in between) work? Chances are you can create a project running on your local machine. It works as you expected, but to let other people access it, you have to “deploy” it. For many years, to support a lot of request volumes you need to run your applications in a data center. These days this setup is known as on-premise. ...

March 24, 2023 · 4 min · Karn Wong

Terraform RDS module with DNS setup

I love not having to manage databases. Hosting it on your compute is guaranteed to be cheaper, but I don’t want to be constantly worrying about backups and database upgrade / maintenance. AWS offers managed databases, known as RDS. Mostly I use postgres, which works well for most use cases. (It’s also a given that - if you don’t really need NoSQL database, then don’t use it). If I spin up RDS postgres, I can reach it assuming I have set up the correct networking pathways. (And you shouldn’t expose your database to public, unless it’s for playground with no sensitive data.) ...

March 17, 2023 · 2 min · Karn Wong

Terraform with ECS task on EC2 backend

Previously I wrote about setting up ECS task on fargate backend. But we can also use EC2 as backend too, in some cases where the workload is consistent, ie scaling is not required, since EC2 would be cheaper than fargate backend, even more so if you have reserved instance on top. There’s a few modifications from the fargate version to make it work with EC2 backend, if you are curious you can try to hunt those down 😎. Repo here. ...

October 4, 2022 · 2 min · Karn Wong

Intro to Pulumi

For IaC, no doubt that Terraform is the leader. But there are other alternatives too, one of them is Pulumi. Currently Pulumi provides fun challenges to get started with their services. Best of all, they give you swags too! We are going to create a simple Pulumi project for hosting a static site through Cloudfront CDN. Challenge url: https://www.pulumi.com/challenge/startup-in-a-box/ Pre-requisites Pulumi account Checkly account AWS acount Install Pulumi cli: brew install pulumi/tap/pulumi Steps Init Init pulumi project ...

September 26, 2022 · 9 min · Karn Wong