Skip to content

Instantly share code, notes, and snippets.

Avatar
🐵
hey there!

Jon Friesen jonfriesen

🐵
hey there!
View GitHub Profile
@jonfriesen
jonfriesen / dreammachine-ddns.md
Last active Apr 22, 2020
Unifi DreamMachine DDNS Fix
View dreammachine-ddns.md

DreamMachine DDNS Fix

In Unifi DreamMachine (UDM) 1.5.*+ setting Dynamic DNS for NameCheap (and other) providers is broken. Monitor this thread on the Ubiquity forums for updates.

This briefly describes the problem and solution.

Problem

The UDM generates a bad URL for updating the NameCheap DDNS domain name. My UDM versions and configuration looks like:

I tried the debug steps and it doesn't appear to update at all.

@jonfriesen
jonfriesen / main.go
Created Mar 17, 2020
Generate SSH key pair in Go
View main.go
// Note: There were a couple blogposts I used to write this but for the life of me can't seem to find them. Will update with references if I do.
// generateSSHKeyPair creates a private & public key pair
func generateSSHKeyPair(bitSize int) (privateKey []byte, publicKey []byte, err error) {
// generate private key
pKey, err := generatePrivateKey(keySize)
if err != nil {
return nil, nil, errors.Wrap(err, "failed to create private key")
}
View gist:8cb6f07b3ee97158a3808adf7d891173
[connection]
id=DO - NYC3
uuid=<COPY_FROM_DUMMY>
type=vpn
autoconnect=false
metered=2
permissions=user:<YOUR_LINUX_USERNAME>:;
timestamp=1581433754
[vpn]
@jonfriesen
jonfriesen / auto-update-vscode.sh
Created Aug 11, 2019
script to auto update vs code
View auto-update-vscode.sh
#!/bin/bash
wget https://vscode-update.azurewebsites.net/latest/linux-deb-x64/stable -O /tmp/code_latest_amd64.deb
sudo dpkg -i /tmp/code_latest_amd64.deb
@jonfriesen
jonfriesen / docker-compose.yml
Created Mar 13, 2019
Spins up PostgreSQL & pgAdmin4 (username: pgadmin4@pgadmin.org password:admin)
View docker-compose.yml
version: '3.5'
services:
postgres:
container_name: postgres_container
image: postgres
environment:
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
PGDATA: /data/postgres
@jonfriesen
jonfriesen / mongo-status-checker.docker-compose.yml
Created Jul 25, 2018
Shows how to create a docker mongo status checker and run command after it connects successfully
View mongo-status-checker.docker-compose.yml
version: '3.0'
services:
mongo:
image: mongo
ports:
- "27017:27017"
- "28017:28017"
environment:
MONGO_INITDB_ROOT_USERNAME: mongoadmin
MONGO_INITDB_ROOT_PASSWORD: secret
@jonfriesen
jonfriesen / docker-builder.sh
Created Jul 24, 2018 — forked from didip/docker-builder.sh
Small helper script that automates Docker building and pushing
View docker-builder.sh
#!/bin/bash
set -ex
PARENT_DIR=$(basename "${PWD%/*}")
CURRENT_DIR="${PWD##*/}"
IMAGE_NAME="$PARENT_DIR/$CURRENT_DIR"
TAG="${1}"
REGISTRY="hub.docker.com"
@jonfriesen
jonfriesen / .travis.yml
Last active Mar 22, 2020 — forked from ryboe/.travis.yml
Example .travis.yml for Golang with CodeCov.io integration
View .travis.yml
language: go
# Only the last two Go releases are supported by the Go team with security
# updates. Any versions older than that should be considered deprecated.
# Don't bother testing with them. tip builds your code with the latest
# development version of Go. This can warn you that your code will break
# in the next version of Go. Don't worry! Later we declare that test runs
# are allowed to fail on Go tip.
go:
- 1.9
@jonfriesen
jonfriesen / template.bat
Created Feb 6, 2018
A simple bat file template
View template.bat
@::!/dos/rocks
@echo off
goto :init
:header
echo %__NAME% v%__VERSION%
echo This is a sample batch file template,
echo providing command-line arguments and flags.
echo.
goto :eof
View interview.md

Hello! What's your background, and what are you working on?

Good Morning! I'm Simon Bennett, a 25-year-old software engineer from the UK. I've always enjoyed building projects for myself on the side and teaching developers. When I am not consulting, I am working on my SaaS SnapShooter - a DigitalOcean backup server

SnapShooter provides a secure and easier way for DigitalOcean users to back up their droplets and volumes. DigitalOcean is very limited in only offering weekly backups and retention of the last four. This was not good enough for me at work so I built a system that enables hourly backups. SnapShooter also offers volume backups which is not offered by DigitalOcean.

Since launching in February to date, SnapShooter has taken 150,000 backups, managing 2,000 droplets and volumes and has 44 paying customers at a MRR of $834.

What motivated you to get started with SnapShooter?

You can’t perform that action at this time.