Deploy to several tenants
Run the same IntuneBrew deployment across many Intune tenants with one command.
Invoke-IntuneBrewBatch.ps1 runs IntuneBrew for a list of tenants in parallel, for example when you manage Intune for several customers or subsidiaries. It needs PowerShell 7 and a clone of the repository.
1. Prepare one configuration per tenant
Each tenant needs its own app registration and a configuration file with the tenant GUID and a certificate thumbprint or client secret. Interactive sign-in isn't possible in a batch.
2. Write a tenant manifest
configFileis relative to the manifest.- Names are 1–80 characters (letters, digits, spaces,
_,.,-) and must be unique. The same tenant can't appear twice.
3. Check the plan
-WhatIf validates every configuration without signing in or deploying anything.
4. Run it
| Parameter | Description |
|---|---|
-TenantManifest | Path to the manifest. Required. |
-Upload or -UpdateAll | What to deploy. Use exactly one. |
-ThrottleLimit | Tenants processed at the same time, 1–10. Default 3. |
-UseExistingIntuneApp, -PreserveAssignments | Passed to every tenant. See the PowerShell reference. |
-SummaryPath | Where to write the results. Default ./intunebrew-batch-summary.json. |
Results
Each tenant runs in its own process and working folder, signed in only to that tenant. The summary file lists every tenant with its status, exit code and duration. The command exits with 1 if any tenant failed; the other tenants still finish.
- Failed tenants are not retried automatically, and nothing is rolled back, because a deployment may have partly completed. Check the tenant before running it again.
- Output from each tenant is hidden to keep credentials out of shared logs. To see what went wrong, run
IntuneBrewdirectly with that tenant's configuration file.