Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

GitHub Engineering 6 min read Case study easyNovice

GitHub Enterprise Cloud with data residency: How we built the next evolution of GitHub Enterprise using GitHub

GitHub Enterprise Cloud gains EU data residency on October 29, 2024, built as a feature set extending Enterprise Cloud on Azure regions rather than a separate product, so it stays in sync with github.com. Changes ship through a unified "deploy then merge" pipeline: employee environments, staged canary on github.com, then the EU data-resident target, all before the pull request merges, with full rollback on any failure. Automation generates consistent deployment pipelines for 100+ services as new regions are added. The team dogfooded an isolated data-resident environment with over 8,000 deploys, and coordinated 100+ teams and 2,000+ issues through GitHub Issues and Projects.

Related posts

  • How we build containerized services at GitHub using GitHub

    GitHub Engineering easyNovice

    GitHub runs hundreds of internal and production services on a "paved path": a Kubernetes-based, multi-cluster, multi-region platform plus conventions and custom tooling layered on top. Services are onboarded via a Hubot ChatOps scaffold command and a GitHub App that opens a PR with deployment.yaml, Kubernetes Deployment/Service manifests, a Debian Dockerfile, and CI checks that build images on every push. Each app/environment gets its own namespace, secrets are injected per-environment from a central vault, and deployments render manifests with the latest image and secrets before applying them across clusters. Centralizing capacity planning, security scanning, base images and deploy tooling lets teams skip cluster management and focus on their applications.

  • How we built multi-region support for Linear

    Linear mediumAdept

    Linear added an EU region by replicating its entire production deployment per region rather than sharding the database, keeping each region isolated and letting engineers keep writing against a single Postgres instance. The work came in three phases: Terraforming the previously hand-managed GCP infrastructure into region-parameterized modules, extracting a global authentication service that owns users, workspaces and their region mapping, and putting a Cloudflare Workers proxy in front of all traffic to route requests to the right region with a signed JWT. Shared records are created and deleted in the auth service first so uniqueness holds globally, updates propagate asynchronously through the sync engine, cross-service calls flow one way (auth to regions via Pub/Sub), and background jobs reconcile the two sides. Fallbacks and feature flags kept cut-overs late and mostly invisible to users.

  • Using GitHub Actions with Heroku Flow for additional Security Control

    Heroku Engineering mediumAdept

    Because GitHub Orgs can't allowlist Heroku IP ranges, Heroku offers a sample pattern: a self-hosted GitHub Actions runner deployed as a Docker app in a Heroku Private Space with static outbound IPs, plus a Heroku Flow Action. The action uses the Platform API's Source Endpoint to upload private repo code, deploy apps on push, dispatch or schedule events, and create, update or remove Review Apps on pull request events. A weekly scheduled workflow rebuilds and redeploys the runner to meet GitHub's 30-day update requirement. Tradeoffs include no repo link in the Review App UI, no automatic Heroku CI tests, no Fir support, and a custom runner image that other actions should be tested against.

  • Security Disclosure Recommendation: Redeploy Buckets and Reconnect GitHub After the Credential Reset

    Railway mediumAdept

    After a security disclosure, Railway invalidated and regenerated S3 access keys for every storage bucket and removed the GitHub tokens it held, including GHCR registry tokens stored on services. These resets show in the audit log under the Railway Staff actor type. Services pick up new bucket credentials only on redeploy because containers read variables at startup, so each service using a bucket needs a redeploy. Any pasted key values should be replaced with reference variables, and external tools need updating. Users must also reconnect their GitHub account and repo sources, revoke and recreate GHCR personal access tokens with read:packages, then check bucket files and audit logs for misuse during the exposure window.

  • Onboarding yourself as an engineer at incident.io

    incident.io mediumAdept

    New 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.

The quest for software engineering knowledge.

Look:
Layout: