Automating Kubeadm Init and Join on Aws My Cloud Homelab Approach

When you’re setting up a Kubernetes cluster using kubeadm, one of the first questions is: “How do I automate the init/join logic without hardcoding IPs or manually copying tokens?” In my AWS-based Kubernetes homelab, I wanted a fully automated, reproducible setup — including both control plane and worker nodes joining the cluster automatically as soon as they boot. This blog explains how I accomplished that using: EC2 instance tags and metadata ...

June 29, 2025

How Rosetta Broke My Terraform Setup (and How I Fixed It on Apple Silicon)

🛠️ How Rosetta Broke My Terraform Setup (and How I Fixed It on Apple Silicon) Everything was working fine — until it wasn’t. While setting up a Kubernetes homelab using Terraform inside a devbox environment on my M1 Mac (macOS 15.5, Apple Silicon), I started hitting this dreaded error: Error: Failed to load plugin schemas Error while loading schemas for plugin components: Failed to obtain provider schema: Could not load the schema for provider registry.terraform.io/hashicorp/aws: failed to instantiate provider "registry.terraform.io/hashicorp/aws" to obtain schema: timeout while waiting for plugin to start.. Re-running terraform validate or terraform plan produced the same issue, even though terraform init was succeeding. ...

June 28, 2025

How to Add git-crypt Contributors to Your Encrypted Git Repository

Managing sensitive information in a Git repository can be challenging, but tools like git-crypt make it easier by encrypting specific files. When adding a new contributor to such a repository, the admin needs to ensure they have the necessary access to decrypt and work with these sensitive values. This tutorial aims to provide a detailed, step-by-step guide to help admins manage contributors effectively, as the official git-crypt repository provides only basic setup instructions. ...

January 11, 2025

Linux Cheat Sheet

Remove execution permission to “others” on every regular files inside a directory find directory_name -type f -exec chmod a-x {} ';' # Avoid using 'chmod -R' as the execution permission is interpreted differently on a directory compared to a regular file. Edit your cron configuration file crontab -e # Always use -e and not crontab file_name # Also do NOT edit it directly in /var/spool/cron/<user> Write errors to the filesystem playbook Determine which filesystem (FS) is full and which file is filling it up 1. `df -h` to look for FS that's 100% or more (possible) full 2. `du -h XX | sort -h` on the identified FS to determine which directory is using the most space. Rinse & repeat command until all the large files are discovered 3. Try `fuser` or `lsof` in case you cant determine which process is using a file Note: `df` & `du` can have disparity in the space reported Write useful shell scripts error messages * Error messages in STDERR * Include name of the program that's issuing the error * State what function / operation failed * If a system call fails, include the perror string * Exit with some code other than 0 Write shell script steps 1. Develop the script as a pipeline, 1 step at a time, on the command line. Use bash. 2. Send output to stdout and check to be sure it looks right 3. At each step, use the shell's command history to recall pipelines and tweak them 4. Once the output is correct, execute the actual commands and verify they worked 5. Use `fc` to capture your work Ex: `find . -type f -name '*.log' | grep -v .do-not-touch | while read fname; do echo mv $fname `echo $fname | sed s/.log/.LOG/`; done | sh -x` Save systemd journal between reboots ...

January 28, 2024

Dockerizing CDKTF with Python

Cloud Development Kit for Terraform (CDKTF) is a framework that allows you to use familiar programming languages to define and provision infrastructure using Terraform. CDKTF supports multiple languages, including Python, which is a popular choice for DevOps engineers. Unfortunately, there is currently no official Docker image for it. Using a Dockerfile, you can ensure that your CDKTF application has all the dependencies and configurations needed to run smoothly and consistently. In this blog post, I will show you the Dockerfile I built for my project that uses CDKTF with Python to create a Kubernetes cluster. ...

December 31, 2023

DevOps - 4 Practices to Reduce Your Lead Time

Create on-demand environments dynamically triggered by a CI/CD pipeline, so teams don’t have to wait weeks. Automate your deployments as much as possible, so any developers can autonomously deploy when needed. Automate your tests and add them to the CI pipeline, so teams can process deployments safely. Design loosely coupled architecture, so developer’s changes are deployed in smaller chunks more frequently with confidence. Those strategies allow teams to improve the delay between the time the customer creates a ticket and its completion.

February 22, 2022

Jenkins As Code With Packer, Ansible, Terraform, and AWS

What Will We Cover Build an OS image for AWS with a Jenkins ready to use Provision an EC2 instance to host the Jenkins server See all the code for this article here: https://github.com/hoaraujerome/devops_cicd Using Packer with Ansible to build an AMI image Packer tool is responsible for creating the OS image, while Ansible is responsible for installing everything we need on this image. The final version of the image has Jenkins (with “GIT”, “Pipeline”, and “Pipeline: AWS Steps” plugins), Docker, AWS CLI, Terraform, and Java installed for running Jenkins pipelines hosted on GitHub. ...

February 7, 2022

DynamoDB: 3 ways to use the API

The way you interact with DynamoDB is usually with AWS SDK, where you can perform: Items-based actions: Anytime you act on a single item - writing, updating, or deleting - you are using an item-based action. You must provide the entire primary key. Query: Read-only actions that allow you to fetch multiple items in a single request. You must provide the partition key and optionally provide sort key conditions. Scan: Full table scan that looks at every item in your table. Avoid it unless you are doing an export or ETL. It’s an expensive operation at scale regarding how long it takes to respond to a request and how much capacity you need to service it. Remember that there is a 1MB limit when reading items from the table. ...

December 14, 2021

5 Responsibilities Regarding the JWT as an API Provider

As a reminder, a JWT (JSON Web Token) is a way for securely transmitting information between parties as a JSON object. As an API provider, here are the actions to take on the received JWT: Validate the signature of the JWT (mandatory) Check if the scope necessary to use your API is present (mandatory). Your API may require more than one scope. Check if the JWT is not expired (mandatory) ...

December 12, 2021

My Thoughts About Java Reactive Programming

Context Traditional Java applications use thread pools for simultaneous I/O operations (such as a REST call). Each request consumes a thread freed at the end of the processing only. So, whenever the thread pool is empty, new requests are blocked waiting for an available thread. This programming paradigm is called imperative or blocking. What is reactive programming? It is a programming paradigm based on the data transmission from one or more sources called Publishers to other elements called Subscribers in an asynchronous, non-blocking, and functional way. Streams combined with the Observable design pattern process all types of data. ...

December 11, 2021