SharpShell

A portable and magic-free way to open Pull Requests from the Command Line

This little bash snippet will let you open a GitHub or GitLab pull request from the command line on most Unix-like systems (OSX, Ubuntu, etc), without using any magic libraries, ZSH tricks or other dependencies. Here's how it looks in action OSX: And Ubuntu: The script is available as the gpr.sh gist. You can also find it in my dotfiles, in the git.sh file. The Script Here's the script in its entirety:
Read more

Manipulating Istio and other Custom Kubernetes Resources in Golang

In this article I'll demonstrate how to use Golang to manipulate Kubernetes Custom Resources, with Istio as an example. No knowledge of Istio is needed, I'll just use it to demonstrate the concepts! Istio is a highly popular Service Mesh platform which allows engineers to quickly add telemetry, advanced traffic management and more to their service-based applications. One interesting element of how Istio works is that when deployed into a Kubernetes cluster, many key configuration objects are handled as Custom Resources.
Read more

Procedural Smiles - Animating SVG with pure JavaScript

I recently needed to be able to generate a simple face image, with the face being able to scale from happy to sad. (Why I needed to do this is a long story!) This gave me the opportunity to have a play with SVG, which is something I've not done in a while and always wished I could spend more time with. You can see the result below, move the slider to see the smile animate:
Read more

Patching Kubernetes Resources in Golang

Recently I needed to be able to quickly adjust the number of replicas in a Kubernetes Replication Controller. The original solution I'd seen pulled down the spec, modified it, then updated it. There's a better way! There's a patch API for Kubernetes resources. Patching resources is faster and easier than pulling them and updating the spec wholesale. However, the documentation is a little limited. After some trial and error I got it working, here's the solution.
Read more

mongo-monitor - a simple CLI to monitor your MongoDB cluster

The mongo-monitor CLI is a lean and simple tool to check the status of a MongoDB server or cluster. The code is on GitHub: github.com/dwmkerr/mongo-monitor Here's how it looks in action: In this animation I am monitoring a simple sharded cluster, and running some example maintenance operations, adding a node to a replicaset, stepping down a primary and shutting down a replicaset node. A simple CLI which shows the status in real-time can be very useful to keep open when performing admin, letting you see how your changes affect the cluster as you work on it.
Read more

The Death of Microservice Madness in 2018

En EspaƱol | Reddit Thread | Hacker News Thread Microservices became a very popular topic over the last couple of years1. ‘Microservice madness’ goes something like this: Netflix are great at devops. Netflix do microservices. Therefore: If I do microservices, I am great at devops. There are many cases where great efforts have been made to adopt microservice patterns without necessarily understanding how the costs and benefits will apply to the specifics of the problem at hand.
Read more

Effective Shell Part 3: Getting Help

This is the third part of my Effective Shell series - practical examples of ways to be more efficient with everyday tasks in a shell. Part 1: Navigating the Command Line Part 2: Become a Clipboard Gymnast Part 3: Getting Help Part 4: Moving Around Part 5: Interlude - Understanding the Shell Part 6: Everything You Don't Need to Know About Job Control Part 7: The Subtleties of Shell Commands In this article I'll show you how to quickly get help when working with tools in the shell, without disrupting your flow!
Read more

Integrating OpenShift and Splunk for Docker Container Logging

In this article I'm going to show you how to set up OpenShift to integrate with Splunk for logging in a Docker container orchestration environment. These techniques could easily be adapted for a standard Kubernetes installation as well! The techniques used in this article are based on the Kubernetes Logging Cluster Administration Guide. I also found Jason Poon's article Kubernetes Logging with Splunk very helpful. First, clone the Terraform AWS OpenShift repo:
Read more

Effective Shell Part 2: Become a Clipboard Gymnast

This is the second part of my Effective Shell series, which contains practical tips for using the shell to help with every day tasks and be more efficient: Part 1: Navigating the Command Line Part 2: Become a Clipboard Gymnast Part 3: Getting Help Part 4: Moving Around Part 5: Interlude - Understanding the Shell Part 6: Everything You Don't Need to Know About Job Control Part 7: The Subtleties of Shell Commands In this article I'll show you how you can use the shell as an efficient tool to compliment how you use the clipboard.
Read more

Effective Shell Part 1: Navigating the Command Line

This is the first part of a series I am writing which contains practical tips for using the shell more effectively. Part 1: Navigating the Command Line Part 2: Become a Clipboard Gymnast Part 3: Getting Help Part 4: Moving Around Part 5: Interlude - Understanding the Shell Part 6: Everything You Don't Need to Know About Job Control Part 7: The Subtleties of Shell Commands I can't think of a better place to start than navigating the command line.
Read more