-
Mac M1 development
For years I’ve been using a Mac for development and it’s been great. But when I switched to a new Macbook Pro M1, an inconvenient truth emerged: I’ve been running development and production on different platforms. Year after year, for bash, python, Ruby, Rails, deploying to real servers, AWS EC2, Docker/Fargate, etc, everything just worked……
-
Ansible inventory management for AWS EC2 on a Small Scale
At TRI, we do everything the hard way… on a small scale. Many online services “best practices” and offerings are fine when you have a large operating budget and staff, and that leaves “smaller” shops with some notable problems to solve. Until recently, we ran a bunch of AWS EC2 instances using Ansible, but Ansible…
-
Discover the public IP address of an AWS Fargate container in a Docker entrypoint script
tl;dr: you must use the +tcp option with dig We needed the public IP address to configure PASV_ADDRESS for a vsftpd service we’re running under AWS Fargate. Unfortunately, there’s no direct way for a Docker entrypoint script to get the current public IP address. There are some annoyingly-complicated ways using AWS api’s, etc, but the…
-
Why you shouldn’t care whether Ansible runs are re-entrant
I recently wrote about a problem I had as a result of imagining that Ansible runs were re-entrant. (Spoiler: they are generally not.) After kicking this around a little I realized that you should not care whether Ansible runs are re-entrant. I like cherry pie so I will explain myself with a pie analogy. If you…
-
Re-entrant vs idempotent in Ansible roles
I wasted a couple hours tracking down a problem with a raft of new AWS ec2 instances generated using Ansible, and it’s worth explaining because it showcases problem common in a lot of Ansible roles. While Ansible docs talk up the concept of “idempotency” (the ability to run a playbook multiple times without screwing up…