Niklas Metje Software engineering enthusiast from Cologne, Germany. Writing about DevOps, Cloud, Deno, Software Engineering, books and everything else that interests me. https://niklasmtj.de/ Automa(tic|g)ally registering ECS task in your AWS Application Load Balancer 2024-07-26T00:00:00Z https://niklasmtj.de/blog/automate-ecs-task-registration-in-alb/ <p>Hey there, 👋! I needed to set up automatic registration of ECS tasks of a service in our load balancer. The previous setups were done by colleagues, but now I had the chance to do it myself. Since we're setting up everything via <a href="https://www.terraform.io/">Terraform</a> as Infrastructure as Code, the example below will be written in <code>hcl</code>, the format that Terraform uses to set up resources.</p> Discover Hidden Space: Understanding Docker Storage Usage with `docker system df` 2024-07-25T00:00:00Z https://niklasmtj.de/blog/understand-docker-storage/ <p>Hey there, 🐳</p> <p>Remember when you first started using Docker and thought you had it all figured out? Well, I've been in the Docker game for quite a while now, and I'm still stumbling upon new tricks. Today, I want to share a nifty little command that blew my mind - <code>docker system df</code>.</p> <p>Ever wondered how much space Docker is taking up on your machine? This command might be your new best friend. Let me show you what I mean:</p> Giving Users Some Privacy Back with E-Mail Aliases: A Personal Take 2024-07-08T00:00:00Z https://niklasmtj.de/blog/give-users-privacy-back-email-aliases/ <p>I've been thinking a lot about email privacy lately. It seems like every website wants our email addresses these days, especially for newsletters. Don't get me wrong, I love a good newsletter, but with all the data breaches and spam out there, I can't help but feel a bit uneasy every time I type in my email address.</p> <p>That's when I stumbled upon the idea of email aliases. It's not a new concept, but it's one that I think deserves more attention.</p> How to get the total CPU and memory of an AWS ECS Fargate cluster using Python 2024-07-04T00:00:00Z https://niklasmtj.de/blog/get-cpu-and-memory-of-ecs-cluster/ <p>Hey there, 👋</p> <p>Have you ever tried to get the total amount of CPU cores and memory of one of your ECS clusters? Today I wrote a script to do just that. I wrote it in Python because the <code>boto3</code> library also powers the AWS CLI, so I thought this might be the best and easiest solution.</p> How to use the Deno `std` library in NodeJS projects 2024-07-01T00:00:00Z https://niklasmtj.de/blog/use-deno-std-library-in-nodejs/ <p>Hey there, NodeJS folks! Ever found yourself wishing you could use some of Deno's standard library features in your NodeJS project? Well, you're in luck! Today we're going to explore how to bring the best of both worlds together. Let's dive in!</p> Setup Deno language server in Zed editor 2024-05-07T00:00:00Z https://niklasmtj.de/blog/setup-deno-in-zed-editor/ <p>Deno has been removed from the <a href="https://github.com/zed-industries/zed/pull/10912">Zed core</a> and is now available as an extension. To install the extension open up the command palette (default is <code>cmd + shift + p</code> and search for <code>zed: extensions</code>). There you can search for <code>Deno</code>.</p> Use the GitHub API Octokit client with Deno 2024-03-20T00:00:00Z https://niklasmtj.de/blog/use-github-api-with-deno/ <p>Using the GitHub API in Deno is as simple as importing the Octokit client shown in the GitHub documentation. Since Deno supports npm packages, you can easily use the Octokit client in Deno. In this short article I will show you how to use the Octokit client to get the workflow runs for a repository.</p> Deno and GitHub Actions workflows 2024-03-09T00:00:00Z https://niklasmtj.de/blog/deno-and-github-actions/ <p>Today I want to talk about Deno and GitHub Actions. For the last year or so, I have only built new projects with Deno. I really like the runtime, it's typescript out of the box config, formatting, linting etc. It is just a lot of fun to work with.</p> <p>Since I still wanted to make sure that everything works when pushed to our Github repositories, I had to build some GitHub actions. Today I want to share a repository where I collect useful actions. At the time of writing, the repository contains 3 different workflows. You can find the repository at <a href="https://github.com/niklasmtj/deno-actions">niklasmtj/deno-actions on GitHub</a>.</p> AWS EKS Cluster without Node Pod Limit with Terraform 2023-12-20T00:00:00Z https://niklasmtj.de/blog/aws-eks-no-node-pod-limits-terraform/ <p><strong>Caution:</strong> If you are using an AWS managed node group, before switching to the launch template below, AWS will delete the current node group and then create the new node group based on the template. Your pod and cluster configuration should not be deleted, but the pods will not be provisioned for the duration of the node change.</p> <p>Since I didn't find the appropriate Terraform resource to start AWS EKS nodes without the AWS-defined pod limits per node, here it is. Why AWS defines limits and how to configure your Amazon VPC CNI plugin can be found in <a href="https://aws.amazon.com/de/blogs/containers/amazon-vpc-cni-increases-pods-per-node-limits/">this blog post from AWS</a>. I will show the Terraform Launch Template resource needed to start the <code>kubelet</code> without the pod limit defined by AWS.</p> Development to Production with GitHub Actions 2023-09-09T00:00:00Z https://niklasmtj.de/blog/development-to-production-with-github-actions/ <p>This blog post will outline a way to get changes from development into production. There are many different ways to do this. This is one way, and there is not <strong>the one</strong> way from dev to production. In the following, I will talk about a way that I have experience with and like the way of the process. The process described in this post will follow the typical Software Development Lifecycle. The definition of it will also not be part of the post. However I will briefly describe what happens in the 3 phases of development, staging and production.</p>