lab-toolkit

IT staff only

Hosting lab-toolkit on spieles.us

How this repo is published, how to add scripts, and the DNS basics for future projects.


1. How it works

GitHub repo (jts44/lab-toolkit, public, branch main)
        │  push
        ▼
GitHub Pages + Jekyll (builds in ~1 min)
        │  .md → .html pages · .sh/.ps1 served raw
        ▼
spieles.us  ← DNS A records point here

2. Everyday workflow

Add or edit a script

cd ~/Documents/GitHub/lab-toolkit
cp templates/mac-template.sh mac/network/flush-dns.sh   # new script
# edit, test locally with --dry-run
git add -A && git commit -m "mac/network: add flush-dns" && git push

Use a script on a lab Mac

curl -fsSLO https://spieles.us/mac/decommission/remove-jamf.sh   # download
less remove-jamf.sh                                              # read
sudo zsh remove-jamf.sh --dry-run                                # preview
sudo zsh remove-jamf.sh                                          # run

Use a script on a lab PC (PowerShell)

irm https://spieles.us/win/system/info.ps1 -OutFile info.ps1
powershell -ExecutionPolicy Bypass -File .\info.ps1

Stale file after a push? GitHub’s CDN caches ~10 min. Force a fresh copy: curl -fsSLO "https://spieles.us/<path>?v=$(date +%s)"


3. Current configuration (reference)


4. DNS in five minutes

DNS maps names to destinations. Each record has a name (host), a type, a value, and a TTL.

Names

Record types you will actually use

TTL and propagation

Checking from Terminal

dig +short spieles.us                 # A records
dig +short AAAA spieles.us            # IPv6
dig +short tools.spieles.us           # CNAME chain
dig +short TXT _github-pages-challenge-jts44.spieles.us
dig +short NS spieles.us              # who hosts the DNS
dig @1.1.1.1 +short spieles.us        # ask a specific resolver (bypass local cache)

On Windows: Resolve-DnsName spieles.us.


5. Pattern for future Git projects

Give each project its own subdomain instead of a new domain.

  1. Create the repo (public), add a CNAME file containing e.g. wiki.spieles.us.
  2. Repo → Settings → Pages → source main / root → custom domain wiki.spieles.us.
  3. Registrar → add CNAME wiki → jts44.github.io (never include the repo name).
  4. dig +short wiki.spieles.us → wait for DNS check successful → Enforce HTTPS.

Already verified at the domain level, so subdomains need no new TXT record.

Safety rules


6. Troubleshooting

Sources: