-
Sphinx Extension Page Generation
5 min read - Aug 12, 2021Following on from a previous blog post on writing Sphinx extensions, a natural requirement is the ability to automatically generate not just content on a single page with your extension, but also content on wholly new pages! Let’s see how that’s done.
-
TypeScript Function Type Parameter Contravariance
11 min read - Jul 25, 2021While reading the excellent “Programming TypeScript: Making Your JavaScript Applications Scale” by @bcherny I managed to confuse myself utterly.
What does it mean for for function type parameters to be contravariant in TypeScript?
Let’s find out! -
Writing a simple external data oriented Sphinx extension
6 min read - May 10, 2021Sphinx is an extremely powerful and elegant way to generate documentation from code. In this guide we’re going to explore how to write a simple Sphinx extension that pulls in data from outside our normal RST files and displays it in any way RST allows us.
-
Querying Appsync With Python
5 min read - May 17, 2020AWS AppSync is a really easy way to quickly assemble a GraphQL API to interact with data from DynamoDB, Lambda, ElasticSearch, RDS, or other HTTP endpoints. You don’t have to create an API Gateway, then fiddle around with hooking it up with DynamoDB mappings, or lambdas in the middle. You define a data model, queries, and mutations, and AppSync provides an endpoint for you to query it. Hell it’ll even go off and create the DynamoDB for you if you use the wizard.
-
Not Authorized to Perform Iam:PassRole
2 min read - Mar 9, 2020I was troubleshooting… as my scenario was a little complicated. I was running Terraform in a Lambda function (as you do) and that lambda’s execution role had just been given permission to assume the OrganizationAccountAccessRole as a troubleshooting step to rule out permissions issues…
-
Hugo CSS Override Failure: Why is everything the same but also different
4 min read - Feb 4, 2020I recently swapped my blog from Ghost to Hugo. While I liked the former (being MarkDown based, lightweight and easy to use), I adore Hugo as you can host it for free with GitHub Pages. Automation Whenever I setup a Hugo site I automate the deployment of it with Travis CI. This means that I can deploy updates to my blog just by editing and creating MarkDown files in GitHub, and as soon as they’re committed to master the updated, rendered, website will be available in a matter of minutes.
-
Testing Submodules' Commit Path within Jenkins Pipeline
5 min read - Mar 10, 2019Submodules? I’ve never been a massive fan of submodules as they come with their own set of complexities and surprises, and embed dependency management within your SCM when really that should be the job of your packaging tool. But sometimes they are the right tool for the job when other tools are absent or your deploy is atypical. I’ve been using them recently to split out code that needed to be shared across repos but which wasn’t available to be distributed via a package repository of any kind.
-
Automated Test Kitchen Checks on GitHub Pull Requests using Docker, TeamCity, and AWS Spot Instances
6 min read - Jul 2, 2018Scenario Being a model Chef user you’re using Test Kitchen to do integration testing of your Cookbooks. It works great on your machine using Vagrant! So let’s make sure these tests always run before code gets merged into Master in the GitHub repo. Why Docker? We’ll be using the chef/chefdk Docker container to run our Kitchen commands because what is the bane of a build agent’s life? Build dependencies! And what’s Docker good at?
-
Creating your own PowerShell Repository with Nexus 3
5 min read - Apr 9, 2017Intro The introduction of PowerShell Gallery in PowerShell 5.0 is something that the Windows world has been craving for a long time (alongside Chocolatey, though I have somewhat mixed feelings about Chocolatey). The PowerShell equivilent to pip, gem, npm, it allows you to install community made PowerShell modules with a single command (Install-Module to be precise!). This is a great way to save yourself from spending hours re-inventing the wheel and easily consume code that someone else has slaved away to make work already.
-
Reporting on PagerDuty call outs with Splunk
4 min read - May 30, 2016Pagerduty has a pretty kickass reporting feature, but my aim is to create a holistic dashboard for my team’s operational work, and to do that I need to have all my data in one place. That one place? Splunk! I love Splunk, have done ever since seeing a presentation on it years ago, but for a long time it stayed out of reach for mere mortals due to its price point.