Dynamic DNS via Digital Ocean API

This is a quick tutorial about setting up a simple shell script that runs periodically to update a DNS record on the internet with the IP address of your network. If you’ve ever wanted to have myhome.mydomain.com always updated with your home IP address, this is one way you can do it. There are paid and free services that offer this functionality, but I choose to use this method because it gives me ultimate flexibility over my domain.
This tutorial assumes you have your own Top Level Domain (TLD) and that you’ve configured it to use Digital Ocean as the authoritative DNS for it. Here, I’ll use “example.com” as the top level domain.

Generate a Personal Access Token

Log in to Digital Ocean and click on API from the top Menu. Click the Generate New Token button and give it a name. The name is not parsed, it’s just for your own reference. I like to give it something descriptive to my application. For this example, I’ll use MyDNS. Be sure to check the box next to Write so we can update the records using this API Key.

Once you have the API Key, save it somewhere for reference. It’s one of the 3 variables we’ll need to update in the update_do_dns.sh script.

The API Key will look something like this:
fe3aeda96b7wer8wer1e6bb5erae528sdf3a6120dfrf7e492bwer6343fsdf

Read more

Using Ansible to build a high availablity Nzbget usenet downloader

I’m limited to about 80MB/s on downloads on my VPC at Digital Ocean, but I run Nzbget for downloading large files from usenet. It doesn’t take long to download at all, but out of curiosity I wanted to see if I could parallelize this and download multiple files at the same. I use Sonarr for searching usenet for freely distributable training videos which then sends them to NZBget for downloading. Since Sonarr can send multiple files to nzbget which get queued up, I figured I can reduce the queue by downloading them at the same time.

Using Ansible and Terraform (devops automation tools), I can spin up VPC on demand, provision them, configure them as nzbget download nodes and then destroy the instances when complete.

Read more

Using Ansible to build a high availablity Sabnzbd usenet downloader

I’m limited to about 40MB/s on downloads on my VPC at Digital Ocean, but I run Sabnzbd for downloading large files from usenet. It doesn’t take long to download at all, but out of curiosity I wanted to see if I could parallelize this and download multiple files at the same. I use Sonarr for searching usenet for freely distributable training videos which then sends them to SABnzbd for downloading. Since Sonarr can send multiple files to sabnzbd which get queued up, I figured I can reduce the queue by downloading them at the same time.

Using Ansible and Terraform (devops automation tools), I can spin up VPC on demand, provision them, configure them as sabnzbd download nodes and then destroy the instances when complete.

The instances all run the same sabnzbd config and the instances use haproxy for round-robin distribution. I will probably change this to Consul, but I just wanted something quick so I used a basic haproxy config.

Read more