---
title: "How we organize and get things done with SERVICEOWNERS"
description: "GitHub added a service layer between code and teams in its 4.2M-line Rails monolith: a SERVICEOWNERS file maps glob patterns, directories and files to named services, and a service-mappings.yaml ties each service to teams, managers, chat channels and tier ratings."
url: "https://swe.quest/articles/how-we-organize-and-get-things-done-with-serviceowners-2afb066a8015a9a4"
canonical: "https://github.blog/engineering/architecture-optimization/how-we-organize-and-get-things-done-with-serviceowners/"
source: "GitHub Engineering"
published: "2023-12-19"
difficulty: "medium"
kind: "Case study"
reading_minutes: 4
tags: ["developer-productivity","engineering-management","ruby","sre"]
---

# How we organize and get things done with SERVICEOWNERS

A post on [GitHub Engineering](https://swe.quest/sources/github.md), published 2023-12-19, 4 min read, Case study. Original: [https://github.blog/engineering/architecture-optimization/how-we-organize-and-get-things-done-with-serviceowners/](https://github.blog/engineering/architecture-optimization/how-we-organize-and-get-things-done-with-serviceowners/)

## Summary

GitHub added a service layer between code and teams in its 4.2M-line Rails monolith: a SERVICEOWNERS file maps glob patterns, directories and files to named services, and a service-mappings.yaml ties each service to teams, managers, chat channels and tier ratings. A serviceowners Ruby gem combines the two to generate CODEOWNERS automatically, so reassigning a service is a one-line YAML change, and it answers ownership queries via a CLI and chat-op. CI enforces rules such as no duplicate patterns, every new file must have a service, and every pattern must match an existing file. ownership.yaml files in other repos feed the same service catalog, letting services span repositories and making on-call contacts, SLOs and dependencies discoverable during incidents.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Developer productivity](https://swe.quest/tags/developer-productivity.md) (Engineering practices)
- [Engineering management](https://swe.quest/tags/engineering-management.md) (Engineering organization)
- [Ruby](https://swe.quest/tags/ruby.md) (Languages)
- [SRE](https://swe.quest/tags/sre.md) (Reliability & operations)

## Prerequisites

- CODEOWNERS files
- monolith vs service architecture ([easy posts on System design](https://swe.quest/tags/system-design.md?difficulty=easy))

## Keywords

SERVICEOWNERS, CODEOWNERS, Ruby on Rails, service catalog, Hubot

## Related posts

- [Organizing ownership: How we assign errors in our monolith](https://swe.quest/articles/organizing-ownership-how-we-assign-errors-in-our-monolith-a4731f02c7358da3.md): incident.io · 2024-11-18 · Medium · 7 min read · Observability, Incidents & postmortems, Go, CI/CD
  incident.io assigns error ownership inside its monolith by dividing the codebase into team-owned units (apps, backend feature packages, integrations), each with a required jsonnet module file declaring owner, criticality and customer-facing features.
- [Using Github Actions with Railway](https://swe.quest/articles/using-github-actions-with-railway-5eb8da35bcdd7f7c.md): Railway · 2021-06-04 · Medium · 2 min read · CI/CD, Deployment
  Railway deployments can be driven from GitHub Actions instead of the built-in branch-push trigger by creating a project token, storing it as a repository secret (RAILWAY\_TOKEN), and running \`railway up --service=\<id\>\` inside the official Railway CLI container.
- [Rolling out Roles](https://swe.quest/articles/rolling-out-roles-feb5c6f49f33b701.md): incident.io · 2022-03-11 · Medium · 6 min read · Identity & auth, Deployment, Product engineering, Go, TypeScript
  incident.io added role-based access control by mapping a fixed set of customer-facing roles (owner, admin, etc.) to granular internal scopes.
- [Under the River](https://swe.quest/articles/under-the-river-4570734a0df8615c.md): Shopify Engineering · 2026-05-28 · Medium · 10 min read · AI agents, Developer productivity, System design, AI for coding, Build systems
  Shopify'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.
- [Working with NX, Railway and CI/CD](https://swe.quest/articles/working-with-nx-railway-and-ci-cd-0bc2b769ee29696c.md): Railway · 2022-09-16 · Medium · 3 min read · CI/CD, Deployment, Build systems, JavaScript
  A GitHub Actions workflow can deploy only the NX monorepo apps affected by a push to Railway, replacing Railway's built-in GitHub trigger.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
