Skip to content

Instantly share code, notes, and snippets.

View tobiasehlert's full-sized avatar
😎
Eat, Sleep, Code, Repeat.

Tobias Lindberg tobiasehlert

😎
Eat, Sleep, Code, Repeat.
View GitHub Profile
@liyangau
liyangau / kong-all-in-one-postgres.yaml
Last active July 29, 2022 13:23
All in one Kong deployment with Postgres DB
version: '2.1'
services:
#######################################
# Postgres: Kong Database
#######################################
kong-db:
image: postgres:12-alpine
container_name: kong-db
networks:
@rossedman
rossedman / main.tf
Last active March 7, 2024 14:00
Scale homelab into cloud with Tailscale, Terraform and cloud-init
terraform {
required_providers {
digitalocean = {
source = "digitalocean/digitalocean"
}
}
}
provider "digitalocean" {
}
@epicserve
epicserve / example.com.import.txt
Last active March 11, 2023 14:04
Example Terraform file for importing DNS Records from DigitalOcean
digitalocean_domain.example example.com
digitalocean_record.example example.com,<DO ID>
digitalocean_record.fd-gmail-txt example.com,<DO ID>
digitalocean_record.fd-mx["alt1.aspmx.l.google.com."] example.com,<DO ID>
digitalocean_record.fd-mx["alt2.aspmx.l.google.com."] example.com,<DO ID>
digitalocean_record.fd-mx["aspmx.l.google.com."] example.com,<DO ID>
digitalocean_record.fd-mx["aspmx2.googlemail.com."] example.com,<DO ID>
digitalocean_record.fd-mx["aspmx3.googlemail.com."] example.com,<DO ID>
digitalocean_record.fd-ns["1"] example.com,<DO ID>
digitalocean_record.fd-ns["2"] example.com,<DO ID>
@tobiasehlert
tobiasehlert / Lindberg-server-toolkit.md
Last active March 1, 2020 11:13
Lindberg server toolkit

Lindberg server toolkit README file

Repo contains

  • setup.sh to as starter script to select what to do
  • add-sshkey-and-rights.sh to add ssh-key(s) to user(s)
  • centos-software-installation.sh to install software on servers

Installation

git clone https://gist.github.com/4b0d23832a30f4e322c5cb35d931a82a.git lindberg-server-toolkit; cd lindberg-server-toolkit; sh setup.sh
@bisand
bisand / README.md
Created September 16, 2019 07:14
Tibber Pulse - Home energy monitor

Tibber Pulse - Home energy monitor

General

Use this flow as an example for how to monitor home energy consumtion using Tibber Pulse, Node-Red and Grafana.

For more information, see node-red-contrib-tibber-api

Resources

@troyfontaine
troyfontaine / README.md
Last active October 15, 2023 09:58
Ubiquiti USG config.gateway.json Syntax

Ubiquiti USG Advanced Configuration

Overview

Integrated DNS Overview

When using a USG with Ubiquiti's Unifi Controller software (version 5.6 and earlier), the functionality of integrating the hostnames of clients (when they request a DHCP lease) into local DNS does not appear to work as you would find with Consumer grade routers. To work around this limitation, we can add static host mappings to a configuration file that will be provisioned to the USG when either a configuration change is made or we force provisioning to the USG itself.

Non-GUI Supported Dynamic DNS Providers

I've added in the necessary syntax for adding Cloudflare DDNS to the USG for VPN/Services setup courtesy of this post by britannic on the Ubiquiti Forums.

Configuration File

@shr00mie
shr00mie / letsencrypt_esxi.sh
Last active November 26, 2023 18:12
Let's Encrypt SSL for ESXi
#!/bin/bash
#
## -----------------------------=[ WARNING ]=-------------------------------- ##
#
# This script is now woefully out of date due to which accounts ESXi allows to
# ssh into the box as well as sticky folders/file flags.
# I've since ported the whole thing to python with a lot of bells and whistles
# and if i get around to making it public, i'll put a link here.
#
## -------------------------------=[ Info ]=--------------------------------- ##
@rsudip90
rsudip90 / nullHandle.go
Last active February 1, 2023 03:34
How I handled the null possible value in a sql database row in golang?
package main
import (
"database/sql"
"encoding/json"
"fmt"
"reflect"
"time"
"github.com/go-sql-driver/mysql"