MSBA-291 · Lesson 12 of 12 · 20 min

Case study: an enterprise governance model

▶ Video coming soon A video version of this lesson is on the way.

The last working session of the year was not a working session at all. Skerry's technology steering committee had asked the platform team to present a single document that described how the new GitHub enterprise would be governed: what was controlled, by whom, how exceptions were handled and how anyone would know it was working. Marisol asked Priya to sit in as the outsider and tell her afterwards which parts she would not have understood without the previous eleven sessions. This lesson presents the problem the committee set, the model the team proposed, and the questions the committee asked.

The brief

The committee's brief fitted on one page.

The steering committee's brief.
The committee wantedConstraint
One governance model for all GitHub use at SkerryCovers the main enterprise, skerry-oss and the planned partner enterprise on GHE.com
Clear ownership of every controlNo control without a named owning team
Developer speed preservedNo new approval step for everyday work
Evidence for the January 2027 auditControls must produce operating evidence automatically
Predictable costLicence and Actions spend reported monthly
A way to change the modelChanges reviewed like code

Read the brief before reading the team's answer, and sketch your own outline: which layers would you govern, which tools from this course would you use for each, and how would you show each one works?

The model: principles

The team opened with four principles, written so that a developer could apply them without reading the rest of the document.

The four governance principles.
PrincipleWhat it means in practice
Restrict the few, open the manyControls apply to actions that are hard to undo; everyday work needs no approval
Target by metadata, not by listRules, configurations and runner access follow custom properties, so new repositories are covered automatically
Machines act as machinesAutomation uses GitHub Apps and workflow tokens, never people's credentials
Every control leaves a recordEach control is chosen partly for the evidence it produces

The model: layers

The heart of the document was a table of layers. Each layer named the controls, where they were configured, who owned them and what evidence they produced.

A stack of governance layers from bottom to top: identity and access; repositories and metadata; rulesets; apps and tokens; Actions policies and runners; packages and supply chain; security configurations; compliance evidence. A vertical bar on the right labelled governance repository and audit log stream spans all layers.
Skerry's governance layers, all managed through the governance repository and evidenced by the audit log stream.
Governance layers, owners and evidence.
LayerControlsConfigured inOwnerEvidence
Identity and accessManaged users, SCIM groups, enterprise teams, roles (MSBA-290)Entra ID and enterprise settingsIdentity engineeringProvisioning logs, access reviews, suspension events
Repositories and metadataCreation and visibility policies, base permissions, required custom properties, templatesEnterprise and organization settingsPlatform teamPolicy change events, property coverage report
RulesetsBaseline enterprise ruleset; confidential, store and tag rulesets; push rulesetsGovernance repository applied through the APIPlatform team with securityRule insights, bypass events
Apps and tokensApproved app list, OAuth restrictions, classic tokens restricted, 90-day fine-grained limitOrganization and enterprise settingsPlatform teamInstallation and authorization events, token exception register
Actions and runnersAllowed actions, lockfiles in stores, read-only token default, fork rules, execution protections, runner groupsEnterprise and organization policiesBuild infrastructurePolicy events, runner registration events, queue and cost metrics
Packages and supply chainWorkflow-only publishing, inherited access, attestations verified at deploymentPackage settings and workflowsBuild infrastructure with securityAttestation verification results
Security configurationsEnforced baseline and code security configurations, push protection, delegated bypass in storesEnterprise and organization configurationsSecuritySecurity overview coverage and alert metrics
Compliance evidenceAudit log streaming for 13 months, saved queries, quarterly report downloadsEnterprise settings and SIEMSecurity with internal auditPopulations and samples on request

Everything as code

A model that lives only in settings drifts. The team's answer to the committee's last requirement was the governance repository introduced in lesson 2. It held the ruleset definitions, the security configuration definitions, the allowed-actions patterns, the runner group definitions and the approved app list, each as a file. A change to any control was a pull request. Its own ruleset required approval from two of the platform, build infrastructure and security teams, and a workflow applied merged changes through the API using a GitHub App with the narrowest permissions that could do the job. The app's private key lived in the vault, and the app was the only actor allowed to change enterprise rulesets.

The layout of Skerry's governance repository.
governance/
  rulesets/
    enterprise-baseline.json
    skerry-confidential.json
    stores-branches.json
    stores-push.json
    release-tags.json
  security-configurations/
    skerry-baseline.json
    skerry-code-security.json
  actions/
    allowed-actions.txt
    runner-groups.yml
  apps/
    approved-apps.yml
  exceptions/
    register.yml
  .github/workflows/
    apply.yml        # applies merged changes through the API as the governance app
    drift-check.yml  # nightly: compares live settings with the files and opens an issue on drift

The drift check was what made the model believable. Every night a workflow read the live settings through the API and compared them with the files. If anything differed, because someone had changed a setting in the web interface during an incident, for example, it opened an issue assigned to the owning team. In the first month it found three drifts, all from emergency changes that had been made correctly but not written back to the files.

Exceptions

No model fits every case. The committee wanted to know how exceptions would work without becoming the norm. The team proposed a register.

An entry in the exception register.
FieldExample
What is exceptedClassic token for the legacy build tool used by 7 repositories
WhyVendor does not yet support fine-grained tokens or GitHub Apps
Compensating controlToken stored in the vault; usage alert on any repository outside the 7
OwnerBuild infrastructure
Approved bySecurity lead and platform lead
ExpiryMarch 31, 2027

Every exception had an expiry date, and the drift check treated an expired exception like drift. The register itself was a file in the governance repository, so approving an exception was a reviewed pull request and the history of exceptions was evidence in its own right. Ottoline's audit team asked for the register as the first item of their January request.

Measuring whether it works

The team proposed a short monthly scorecard. Each measure had a target and an owner, and each could be produced automatically.

The governance scorecard.
MeasureTargetSource
Repositories with required custom properties set100 percentCustom property report
Repositories covered by the baseline security configuration100 percent within one day of creationSecurity overview
Ruleset bypasses with a linked incident or change100 percentBypass events joined to the incident system
Critical code scanning alerts older than 14 daysZeroSecurity overview
Open token exceptions past expiryZeroException register
95th-percentile runner queue timeUnder 2 minutesActions metrics
Licences assigned to people inactive for 90 daysUnder 3 percentLicence and activity reports
Drift issues open longer than 7 daysZeroGovernance repository issues

Worked problem

Working out a licence measure

In November, Skerry's main enterprise had 1,180 consumed licences, and 47 belonged to people with no activity in 90 days. Does it meet the target of under 3 percent?

Show solution
  1. Divide 47 by 1,180.
  2. That is about 0.040.
  3. So about 4 percent of licences are inactive, which is above the 3 percent target.

Answer: No; about 4 percent are inactive, so the identity team reviewed those 47 accounts with managers before the next billing date.

Roles and responsibilities

The committee asked who would do what. The team answered with a compact responsibility table, in which R means responsible for doing the work, A accountable for the outcome, C consulted and I informed.

Who does what in the governance model.
ActivityPlatformBuild infrastructureSecurityIdentityInternal audit
Change rulesetsR/ACCII
Change security configurationsCIR/AII
Change Actions policies and runnersCR/ACII
Approve apps and token exceptionsRCAII
Provision and remove accessIICR/AI
Produce audit evidenceRCACC

Risks the team named

A good governance document names its own weaknesses. The team listed four.

Risks and responses in the governance model.
RiskWhy it mattersResponse
Platform features keep changingLockfiles, execution protections and enforcement options all arrived in the last few monthsQuarterly review of GitHub's changelog against the model
The governance app is powerfulIt can change enterprise rulesetsNarrow permissions, key in the vault, every change from a reviewed pull request
Developers route around controlsFriction leads to shadow toolsScorecard includes queue times and exception counts; office hours each week
A second enterprise driftsThe partner enterprise on GHE.com is managed separatelyThe same governance repository applies to both, with environment-specific files

The committee's questions

The committee asked three questions. The first was whether the model slowed developers down. Marisol's answer was the data group pilot: median time from pull request to merge had fallen from 19 hours to 11, mostly because reviews no longer waited for an administrator to override broken branch protection. The second was what happened if GitHub had an outage. Freya explained that the model governed GitHub but did not make Skerry depend on it any more than before, and that the incident runbook included the break-glass access from MSBA-290 and a plan for store deployments to continue from the last attested images. The third was whether the model would survive the platform team being busy. The answer was the drift check and the scorecard: both ran without anyone remembering to run them.

Worked problem

Testing the model against a scenario

A new team in the data group creates a repository for a customer-facing recommendation service and sets data-classification to confidential. List what the model does automatically, without anyone in the platform team acting.

Show solution
  1. The confidential-code ruleset applies to its default and release branches, requiring two approvals, code owner review, a passing build and code scanning results.
  2. The code security configuration applies, turning on code scanning default setup, dependency review, secret scanning and push protection.
  3. Runner groups allow the repository to use the standard and Azure private runners but not the store runners.
  4. Alerts route to the owning team from the owning-team property.
  5. Every action the team takes appears in the audit log stream.

Answer: Rulesets, security configurations, runner access and alert routing all follow the confidential classification automatically, and the audit log records the rest.

Debrief

Priya's feedback to Marisol afterwards was that the document was clear, but that she would not have understood why custom properties mattered so much without lesson 1, or why lockfiles mattered without lesson 5. The committee did not need those details; the developers did. The team added a one-page developer guide to the governance repository, written as answers to the questions developers actually asked: why can I not merge, how do I get an app installed, why did my token stop working and where do I ask for an exception.

That closes the GitHub administration story for this course. MSBA-299 reviews it against the GH-100 exam domains, from support and deployment through identity, access, policies, Actions and security, with practice questions written for the exam's style.

How the model changes

A governance model is never finished. The team agreed three triggers for revising it. First, GitHub releases: someone in the platform team read the changelog weekly, and any change that touched a layer, such as a new ruleset rule, a policy option or a change to defaults like the December 2026 pull_request_target block, was assessed within a month. Second, incidents: every incident review asked whether a control had failed, been bypassed or been missing. Third, the quarterly scorecard review: a measure that stayed red for two quarters meant the control or its target was wrong.

Changes to the model itself followed the same path as changes to any control: a pull request to the governance repository, with the reasoning in the description and approval from the owning teams. The document the committee read was generated from that repository's README, so it could not fall out of date with the controls it described.

Triggers for revising the governance model.
TriggerExampleExpected response time
GitHub changelog entry affecting a layerLockfiles reach general availabilityAssessed within a month
Incident involving a controlA bypass used without a linked incidentReviewed in the incident follow-up
Scorecard measure red for two quartersInactive licences stay above targetControl or target revised at the next quarterly review
New enterprise or major acquisitionThe partner enterprise on GHE.comModel applied before the first developer joins

Common mistakes

  • MistakeWriting governance as a document of settings to configure once.

    InsteadKeep controls as code, apply them automatically and check for drift.

  • MistakeAllowing exceptions without expiry dates.

    InsteadGive every exception an owner, a compensating control and an expiry.

  • MistakeMeasuring only security outcomes.

    InsteadMeasure developer experience and cost too, or controls will be routed around.

  • MistakeGoverning a second enterprise separately.

    InsteadApply the same model from the same repository to every enterprise.

Summary and key terms

  • A governance model names its principles, layers, owners, evidence, exceptions, measures and risks.
  • Targeting by custom property lets one model cover new repositories automatically.
  • Keeping controls as code in a governance repository gives review, history and drift detection.
  • An exception register with owners, compensating controls and expiry dates keeps exceptions rare.
  • A monthly scorecard covers security, developer experience and cost.
  • The audit log stream turns the model into evidence without extra work.
Governance model
A description of what is controlled, by whom, how exceptions work and how success is measured.
Governance repository
A repository holding control definitions as files, applied through the API.
Drift check
An automated comparison of live settings with their definitions in code.
Exception register
A record of approved deviations with owners, controls and expiry dates.
Compensating control
A safeguard that reduces risk when a standard control cannot apply.
Scorecard
A short set of measures with targets that show whether governance is working.

Practice problems

Work each problem on paper first, then reveal the answer to check.

  1. What does the nightly drift check do?

    Show answer

    Compares live settings with the governance files and opens an issue when they differ.

  2. Which three fields make an exception safe to grant?

    Show answer

    An owner, a compensating control and an expiry date.

  3. Why include runner queue time in a governance scorecard?

    Show answer

    Slow or blocked developers route around controls, so experience is part of governance.

Lesson quiz · 5 questions

Score 60% or more to complete this lesson.

Take the quiz