When a web server creates a web page it generally pulls loads of crap from the database/disk and stitches together some ginormous hodgepodge of raw markup hundreds or thousands of kilobytes in size. As HTML is literally just a heap of embarrassingly compressible plaintext, turning on nginx’s gzip compression filter is a no-brainer. gzip on;… Continue reading Finding the Nginx gzip_comp_level Sweet Spot
Author: Alan Orth
GNU/Linux, Indian food, and Death Metal!
Leveraging the Ansible Python API for Infrastructure Reporting
A few days ago I had to get some basic information from a handful of servers for an inventory report—just basic stuff like hostname, IP address, storage capacity, distro version, etc. I already manage all of my servers with Ansible, and there’s a wealth of information available in Ansible’s setup module, so I knew there… Continue reading Leveraging the Ansible Python API for Infrastructure Reporting
Maps and Custom Error Pages in Nginx
During a recent web application upgrade I had to limit access to the the web servers; I wanted the administrators and myself to be able to access the site, but for everyone else to see an “Under Construction” page. My initial plan was to test if the $remote_addr was one of the allowed IPs, and… Continue reading Maps and Custom Error Pages in Nginx
Image Compression Like Compressor.io, but With Open-Source Tools
When I first tried Compressor.io I was shocked. How can they reduce an image’s file size by hundreds of kilobytes or more without downscaling the image and no noticeable loss in quality? Although it’s a cool, free tool, it bothered me that, because I didn’t know how to do this myself, I was depending on… Continue reading Image Compression Like Compressor.io, but With Open-Source Tools
Update Hosts via Ansible to Mitigate Bash “Shellshock” Vulnerability
On September 24, 2014 someone posted on the oss-sec mailing list about a bash vulnerability that likely affects several decades of bash versions (something like 1.14 – 4.3!). The vulnerability — aptly named “Shellshock” — can lead to remote code execution on un-patched hosts, for example web servers parsing HTTP environment variables via CGI GET… Continue reading Update Hosts via Ansible to Mitigate Bash “Shellshock” Vulnerability