This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(cors) { | |
@cors_preflight{args.0} method OPTIONS | |
@cors{args.0} header Origin {args.0} | |
handle @cors_preflight{args.0} { | |
header { | |
Access-Control-Allow-Origin "{args.0}" | |
Access-Control-Allow-Methods "GET, POST, PUT, PATCH, DELETE, OPTIONS" | |
Access-Control-Allow-Headers * | |
Access-Control-Max-Age "3600" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%s/{% gist ryanburnette\/\([a-z|0-9]\{20}\) %}/<%= gist "ryanburnette", "\1" %>/g |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
sed -i 's:^deb :#deb :g' /etc/apt/sources.list.d/pve-enterprise.list | |
wget http://download.proxmox.com/debian/proxmox-release-bullseye.gpg -O /etc/apt/trusted.gpg.d/proxmox-release-bullseye.gpg | |
echo '# pve-no-subscription repository provided by proxmox.com, not recommended for production use | |
deb http://download.proxmox.com/debian/pve bullseye pve-no-subscription | |
' > /etc/apt/sources.list.d/pve-no-subscription.list | |
apt update | |
#pveupgrade |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -z "$1" ]; then | |
echo "Usage: $0 <directory>" | |
exit 1 | |
fi | |
dir="$1" | |
if [ ! -d "$dir" ]; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
await postmark.sendEmail({ | |
From: 'api@ryanburnette.com', | |
ReplyTo: `${req.body.xname} <${req.body.xemail}>`, | |
To: to, | |
Cc: 'api-submissions@ryanburnette.com', | |
Subject: `ryanburnette.com api submission to ${req.body.form} from ${req.body.xname}`, | |
HtmlBody: html, | |
TextBody: text, | |
MessageStream: 'outbound', | |
Headers: [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get update | |
sudo apt-get install --yes ca-certificates apt-transport-https wget | |
echo 'deb https://www.ui.com/downloads/unifi/debian stable ubiquiti' | sudo tee /etc/apt/sources.list.d/100-ubnt-unifi.list | |
sudo wget -O /etc/apt/trusted.gpg.d/unifi-repo.gpg https://dl.ui.com/unifi/unifi-repo.gpg | |
sudo apt update | |
sudo apt install --yes openjdk-8-jre-headless unifi | |
service unifi stop |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -u | |
sudo timedatectl set-timezone America/New_York |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;(function() { | |
function myModule() { | |
} | |
if (typeof module !== 'undefined' && typeof module.exports !== 'undefined') { | |
module.exports = myModule; | |
} | |
else { | |
if (typeof define === 'function' && define.amd) { | |
define([], function() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(asset-paths) { | |
path *.bmp *.jpg *.png *.svg *.gif *.pdf *.css *.js | |
} | |
(cache) { | |
@content { | |
not { | |
import asset-paths | |
} | |
} | |
header @content cache-control max-age=0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
hostname=`hostname` | |
emaildomain='' | |
alertemail='' | |
mailgunapikey='' | |
# max capacity % before getting capacity alert | |
maxCapacity=80 |
NewerOlder