From Snowflake Servers to GitOps Nirvana

8 open-source tools you can combine so that git push deploys your entire stack.

View the GitOps Glossary

You’ve probably heard the buzzwords: GitOps, NoOps, immutable infrastructure.
Today I’d like to walk you—step by step—through why these concepts exist and how a small constellation of tools (Git, NixOS, Docker, Terraform, Kubernetes, ArgoCD, DSPy, and OPA) fit together to create a platform that deploys itself every time you hit merge.

Quick tool map (click to open)
Git NixOS Docker Terraform Kubernetes ArgoCD DSPy OPA

1. The Problem We’re Solving

In the old world, a server was a pet: lovingly hand-fed config files, patched on Sundays, and inevitably different from every other server. The result?

2. The North Star: Everything as Code

Instead of pets, we want cattle - identical, replaceable, and defined in text files that live in Git.
If Git is the single source of truth, the rest of the stack becomes a conveyor belt that turns that truth into running software.

3. The Cast of Characters and Their Jobs

Full tool map (click to open)
Tool One-Sentence Job Why It Matters
Git The single source-of-truth for every line of code and config. Immutable history + pull-requests = collaboration without chaos.
NixOS An entire Linux distro expressed in one declarative file. Reinstalls laptop or 1 000-server fleet with nixos-rebuild.
Terraform Describe cloud resources (VPCs, disks, IAM) in HCL. Re-creates an entire region from scratch in 15 min after a coffee spill.
Docker Bundle the app and its libraries into an immutable image. Same artifact runs on your Mac, in CI, and in prod.
Argo CD A robot that watches Git and makes Kubernetes match it. Manual kubectl apply is now a pull-request review.
Kubernetes The planet-scale scheduler that keeps those containers healthy. Auto-heals, scales, and rolls out with zero downtime.
DSPy Prompt-engineering as typed, testable code. Turns LLM prompts into reproducible pipelines.
OPA / Kyverno Policy-as-code gatekeepers for every API call. Blocks :latest images or unencrypted buckets before they deploy.

4. How the Characters relate to Each Other

Declarative GitOps workflow Declarative GitOps workflow

💡 Press Ctrl + + / -, or pinch-zoom on mobile to enlarge the diagram. Right Click to Open Image in New Tab.

5. A Day in the Life of a Change

Let’s add a new feature: “Show real-time in-game leaderboards”.

  1. Code

    • Write the leaderboard service in Go.
    • Add a DSPy pipeline to pre-aggregate stats.
    • Commit everything to git.

  2. CI Gate

    • Nix builds the Docker image (bit-for-bit reproducible).
    • Terraform dry-run shows a new Redis cache.
    • Tests pass → image is signed & pushed.

  3. GitOps Sync

    • Argo CD detects the new commit hash.
    • Kubernetes manifests are applied; pods roll out blue-green.
    • OPA policy ensures the service can’t talk to the payments DB.

  4. Observe

    • Prometheus sees p95 latency drop.
    • Grafana dashboard auto-updates.
    • No humans touched a server.

6. Beginner Take-aways

📦 Grab the configs

7. The Bigger Picture

Declarative, Git-driven stacks aren’t tools; they’re a culture.
When everything is code, knowledge lives in the repo, not in someone’s head.
That means faster onboarding, fearless refactors, and - best of all - Friday deploys that don’t ruin weekends.

Welcome to the Declared World: where the robots do the toil, and we get back to building great games.