Skip to content

Instantly share code, notes, and snippets.

View felddy's full-sized avatar
🌎
In low Earth suborbit

Mark Feldhousen felddy

🌎
In low Earth suborbit
View GitHub Profile
@felddy
felddy / touch-vtt-issue-61-patch.sh
Created November 28, 2023 17:53
Patch for FoundryVTT to correct issue 61 of the touch-vtt module
#!/bin/ash
# Touch-VTT Issue 61 Fix
# =====================
PATCH_DOC_URL="https://github.com/Oromis/touch-vtt/issues/61"
PATCH_NAME="Fix for touch-vtt issue #61"
log "Applying \"${PATCH_NAME}\""
log "See: ${PATCH_DOC_URL}"
@felddy
felddy / add-hash-tags.py
Created September 1, 2023 23:40
Script to add comments containing tag labels for sha-pinned GitHub Action uses
#!/usr/bin/env python3
import argparse
import os
import re
import subprocess
import json
from packaging.version import parse as parse_version
from functools import lru_cache
@felddy
felddy / check-foundry-dns.sh
Last active August 7, 2023 20:24
Check FoundryVTT public DNS and create a markdown table of the results
#!/bin/bash
# Initial list of domains
DOMAINS=("api.foundryvtt.com"
"foundryvtt.com"
"foundryvtt.s3.amazonaws.com"
"foundryvtt.s3.dualstack.us-west-2.amazonaws.com")
# Print the table header
echo "| Name | \`A\` | \`AAAA\` | Notes |"
@felddy
felddy / log_test_patch.sh
Created January 1, 2022 22:00
foundryvtt_docker patch file that tests out the logging calls
#!/bin/sh
log_debug "This is a debug message."
log "This is an info message."
log_warn "This is a warning message."
log_error "This is an error message."
@felddy
felddy / no-aaaa.py
Last active August 9, 2023 23:56 — forked from FiloSottile/no-aaaa.py
Unbound python-script to block AAAA records of Netflix domains.
def init(id, cfg):
return True
def deinit(id):
return True
def inform_super(id, qstate, superqstate, qdata):
return True
domains = [
@felddy
felddy / docker-compose.yml
Last active August 14, 2021 14:00
Run two Foundry Virtual Tabletop instances from the same docker-compose file.
---
version: "3.8"
secrets:
credentials:
file: credentials.json
services:
foundry_1:
image: felddy/foundryvtt:release
@felddy
felddy / Caddyfile
Last active August 28, 2020 12:04
Example of running FoundryVTT behind Caddy.
{$SITE_ADDRESS} {
reverse_proxy foundry:30000
tls {$LETSENCRYPT_EMAIL} {
# Comment out next line to use production CA
ca https://acme-staging-v02.api.letsencrypt.org/directory
}
}
@felddy
felddy / README.md
Last active March 10, 2020 02:18
Rendering HTML reports with puppeteer.
yarn install
./render.js https://fivethirtyeight.com 538.pdf
@felddy
felddy / iam_to_travis.py
Last active July 11, 2019 17:36
Export creds from an AWS IAM user to a encrypted variable for Travis.
#!/usr/bin/env python
import json
import subprocess
import sys
def creds_from_child(child_module):
for resource in child_module["resources"]:
if resource["address"] == "aws_iam_access_key.key":
@felddy
felddy / put_file_to_ssm_param.py
Last active July 11, 2019 21:11
Create SSM Parameters in multiple regions from a file.
#!/usr/bin/env python
"""Create SSM Parameters in multiple regions.
Usage:
put_file_to_ssm_param put [--log-level=LEVEL] [--overwrite] <parameter_name>
<filename>...
put_file_to_ssm_param delete <parameter_name>
put_file_to_ssm_param (-h | --help)