git
Technical notes on web development, DevOps, and AI integration.
17 articles
- 11:17devops
Restart Is Not Deploy: A Pre-Flight Gate for the API Container
A restart gate that refuses while the tree is dirty.
TL;DR: Restarting a bind-mounted container deploys whatever sits in the working tree, so a half-finished refactor went live uncommitted. The fix is a restart script that refuses to run when the served path is dirty, using git status porcelain. The guard narrows but doesn't close the race window between check and start.
#docker#compose#bash - 20:30devops
Switching Deploys to Vercel: The Lock Is Outside the Code
The diff was docs-only, yet the deploy migration from Cloudflare Workers to Vercel still happened. The wiring lives in the Vercel dashboard and GitHub settings, not in the repo.
TL;DR: A docs-only commit revealed the Workers-to-Vercel migration left almost no trace in Git, since the wiring lives in Vercel and GitHub settings. Vercel elects the production branch only at import, so the GitHub default branch stag and production branch main are two independent switches. Env variables need per-target re-registration, and rollback is repointing a deployment, not git revert.
#vercel#cloudflare#git - 02:25devops
Subtree Split or Rsync Snapshot: Picking the Publish Mechanism
One folder or five scattered paths? The shape of your include set decides when subtree split is safe and when an rsync snapshot wins.
#git#rsync#forgejo - 22:24devops
WordPress Full vs View: Two Git Repos, Two Different Jobs
One WordPress install, two Git repos: a full Forgejo repo for recovery, a GitHub view repo carrying only source I wrote myself.
#wordpress#git#github - 20:23devops
Dual-Push, Pull Mirrors, and Forgejo's Ground Rules
My per-commit dual-push ritual turned out more honest than a pull mirror that would quietly drop a 631 MB branch GitHub never had.
#git#forgejo#github - 16:29devops
Forgejo as a Secondary Git Host for Files GitHub Rejects
GitHub's 100 MB file block nearly ate a 631 MB backup bundle. The fix I picked: a self-hosted Forgejo secondary with proper mirror patterns.
#git#forgejo#github - 22:39devops
That Morning .gitignore Commit Made Me Rethink My Backup Setup
A two-line .gitignore whitelist commit turned into a full backup redesign: Git repo, restic, immutable cloud, 3-2-1-1-0 without a NAS.
TL;DR: A two-line .gitignore change led me to audit my backups, and I realized my NAS setup was untested and ransomware-vulnerable. I replaced it with a 3-2-1-1-0 approach: git bundles, restic snapshots, and immutable cloud storage. Monthly restore drills now verify the whole thing actually works.
#backup#git#restic - 21:39devops
A main/staging/api Branch Strategy: Safe Deploys with Vercel Previews and GitHub Actions
A three-lane branch model for safe deploys: main as the source of truth, staging for Vercel previews, api for VPS deploys via GitHub Actions.
#vercel#nextjs#github-actions