Infra at Scale: Agents, Tools and Infra-as-Code
Benchling uses scheduled AI agents (Cursor Cloud Agents) to roll out routine updates to 30+ Kubernetes cluster components (Helm charts, AMIs, container images) through dev, staging and prod, while keeping a human approval on every PR. Component versions live in per-stage constants files compiled into per-cluster Terraform variables, so each stage upgrade is a one-line change. Per-component rollout configs tell the agent where to find releases, what to check in release notes, how to verify in dev and how long to bake. A stateless tick derives its position from those files and git history. Reviewers pre-approve Terraform runs via "plan matcher" expressions in the PR, which a Reviewer service checks before auto-applying. The result is hundreds of merged PRs at roughly five times the previous cadence, and in one case the agent caught a breaking default-value change in a network controller.
Related posts
- Agentic Coding on Railway: A Practical Guide for 2026
Railway mediumAdeptRailway's official MCP server, per-PR preview environments with isolated databases, one-call rollback, environment promotion and per-environment secrets let agents like Claude Code, Cursor and Codex deploy, debug and validate their own PRs without leaving the loop. Five workflows are walked through: scaffolding and deploying a service, adding Postgres with migrations, creating preview environments, debugging failed deploys from structured logs, and agents testing their own PRs against preview URLs. Long-running migrations, multi-service ordering and cost reasoning still stall. The advice is to scope agent tokens to non-production environments, require human approval for production promotions, set spend alerts, watch for revert loops, add observability via MCP, and write business constraints where the agent can read them.
- Shipping huggingface_hub every week with AI, open tools, and a human in the loop
Hugging Face mediumAdepthuggingface_hub moved from releases every 4-6 weeks to weekly releases driven by a single GitHub Actions workflow that automates versioning, tagging, PyPI publishing, downstream test branches, post-release bumps and Slack reporting, with an open-weights model (GLM via HF Inference Providers, run through OpenCode) drafting release notes and announcements. The key pattern wraps the model in deterministic guardrails: a script extracts PR numbers from squash-merge commits as a manifest, diffs it against PRs referenced in the draft, and re-prompts the agent to fix missing or extra entries. The model is grounded with docs diffs from each PR, and a human edits the draft before promoting the RC. Publishing uses PyPI Trusted Publishing with OIDC and Sigstore attestations plus a checksum-pinned agent runtime, and each release costs about $0.25 in inference.
- Under the River
Shopify Engineering mediumAdeptShopify's Slack-native agent River co-authors one in eight merged PRs, and it rests on two 2024 bets: a single monorepo (World) and Nix-built reproducible environments across dev, CI and production. Underneath sits Aquifer, an internal agent platform built so the session outlives any process. A Postgres-backed append-only event log holds the conversation, the agent harness runs outside a disposable sandbox, and ephemeral session cells are recreated on demand. Agents are shipped as Nix-built profile bundles across interactive, automation and job modes. Lessons for agent infrastructure: decouple the brain from the hands, make agents public and multiplayer so transcripts compound into shared skills, and treat each new agent as a profile rather than a new platform.
- How We Use Terraform At Slack
Slack Engineering mediumAdeptSlack runs roughly 1,400 Terraform state files across AWS, GCP, DigitalOcean and NS1, split per account, region and large service so each change touches fewer resources. State lives in a versioned S3 backend with DynamoDB locking and is deployed by Jenkins plan/apply pipelines chained through sandbox and dev before production, while engineers plan safely from read-only "Ops" boxes. After a painful quarter-long 0.11→0.12 upgrade, the team built a wrapper that installs multiple Terraform and provider versions and picks one per state file from versions.tf. They also wrote a Go-based upgrade tool that checks remote-state dependencies and plans after upgrading. Modules moved from relative paths and git refs to an internal S3-backed catalog of versioned tarballs, which state files pin via vendored_modules.
- Onboarding yourself as an engineer at incident.io
incident.io mediumAdeptNew engineers at incident.io onboard themselves by opening a PR to the infrastructure repo that adds them as a user, puts them on a team in a Jsonnet config, and defines a Spacelift dev stack. Once merged, Terraform provisions their dev environment, grants Google Cloud access based on user tags, and syncs Google Group memberships from the same config. The Catalog Importer then maps that team data into incident.io's Team catalog type, so the company's own product is configured as code alongside GCP, Sentry and Spacelift.