
Endpoint Management
Configuration as Code for Endpoint Management
Configuration as Code for Intune with Microsoft365DSC: version control, drift detection, and automated deployment via Git, without becoming a developer.
By Paul Bentley7 min read
Windows Endpoint Management · Part 2 of 4
On this page
- The problem with console changes
- "We're not developers"
- The real barrier is process discipline
- Getting started in four phases
- Phase 1: read-only visibility
- Phase 2: drift detection
- Phase 3: pipeline deployment
- Phase 4: full GitOps with branch protection
- Common objections
- "What about urgent fixes?"
- "Our team doesn't have time to learn this."
- "We tried Git before and it was a mess."
- "Microsoft365DSC isn't mature enough."
- What changes after six months
- Next steps
The problem with console changes
Every change you make in the Intune console is a liability, because a console click leaves no record of intent. The console itself is not to blame.
There is an audit log, and it will tell you that someone changed a configuration profile at 14:32 on Tuesday. It won't tell you why, whether anyone tested the change, or whether it was deliberate. You feel the gap three weeks later, matching symptoms against audit entries by hand while something is broken.
This is how configuration drift starts. An engineer tweaks a setting to fix an urgent issue. Unaware of it, a second engineer makes a conflicting change in a different profile, and a third copies a profile for a new use case and changes it slightly. Six months later you have seventeen "Standard Device Configuration" profiles, none of them match, and nobody can say what "standard" means.
Configuration as Code moves the configuration into files in a Git repository. That changes five things:
- You read the configuration as files, instead of as state in a database somewhere in Microsoft's infrastructure.
- Every change records who made it and when, and the commit message records why.
- Changes go through pull requests, so a second person sees a mistake before it reaches production.
- The same files rebuild the configuration in a test tenant, after a disaster, or for a new team member to study.
- If a change breaks something, you revert the commit, run the pipeline, and the tenant returns to the last known good state.

