This project provides automated evaluation and assessment of Azure Landing Zone implementations based on the official Azure Landing Zone Framework. It delivers comprehensive analysis across all design areas with intelligent automation, modern PowerShell architecture, and interactive visualization.
- π Comprehensive Assessment: Evaluates 8 core design areas of Azure Landing Zone
- β‘ Modern Architecture: Optimized PowerShell codebase with shared context, caching, and standardized error handling
- π Interactive Dashboard: Beautiful web-based visualization with charts, tables, and detailed insights
- ποΈ Flexible Configuration: Tenant-scoped evaluation with configurable design areas
- π§ Exception Handling: Manual override capabilities for specific organizational requirements
- π Detailed Reporting: JSON reports, error logs, and execution transcripts
- π‘οΈ Secure by Design: Tenant-scoped authentication with proper context isolation
- Structured JSON Report (
reports/report.json) with detailed findings - Interactive Web Dashboard (
web/index.html) with charts and tables - Comprehensive Error Logging with troubleshooting information
- Execution Transcripts for audit and debugging purposes
- Exception Management for customized assessments
LandingZoneAssessment-Automate/
βββ π bicep/ # Infrastructure as Code (Bicep)
βββ π arm/ # ARM templates for Azure resources
βββ π scripts/ # π§ Main execution scripts
β βββ Main.ps1 # Primary assessment execution
β βββ Initialize.ps1 # Environment setup and authentication
β βββ CreateWebSite.ps1 # Dashboard generation
βββ π functions/ # π§© Assessment modules (modernized architecture)
β βββ AzureBillingandMicrosoftEntraIDTenants.ps1
β βββ IdentityandAccessManagement.ps1
β βββ ResourceOrganization.ps1
β βββ NetworkTopologyandConnectivity.ps1
β βββ Governance.ps1
β βββ Security.ps1
β βββ PlatformAutomationandDevOps.ps1
β βββ Management.ps1
βββ π shared/ # π Shared infrastructure
β βββ config.json # Configuration settings
β βββ alz_checklist.en.json # Assessment checklist
β βββ exceptions.json # Manual overrides
β βββ Enums.ps1 # Status enumerations
β βββ SharedFunctions.ps1 # Common utilities
β βββ ErrorHandling.ps1 # Centralized error management
βββ π web/ # π Interactive dashboard
βββ π reports/ # π Generated reports
βββ π logs/ # π Execution logs and transcripts
βββ π Debug/ # π Debugging utilities
- Shared Context & Caching: All modules use
$global:AzDataand$global:GraphDatafor optimized resource queries - Standardized Error Handling: Centralized error logging with
Write-ErrorLogfunction - Consistent Status Enums: All assessments use standardized
Statusenum values - Tenant-Scoped Security: Strict tenant isolation with context enforcement
- Modular Design: Each design area is self-contained with dot-sourced dependencies
- PowerShell 5.1 or PowerShell Core 7.x
- Azure PowerShell modules (automatically installed)
- Microsoft Graph PowerShell modules (automatically installed)
- Appropriate Azure permissions (Reader role minimum)
- Microsoft Entra ID permissions (varies by assessment)
Edit shared/config.json with your tenant details:
{
"TenantId": "your-tenant-id-here",
"DefaultSubscriptionId": "",
"DefaultRegion": "eastus",
"ContractType": "EnterpriseAgreement",
"AlzChecklist": "alz_checklist.en.json",
"DesignAreas": {
"Billing": true,
"IAM": true,
"ResourceOrganization": true,
"Network": true,
"Governance": true,
"Security": true,
"DevOps": true,
"Management": true
}
}- π Set your Tenant ID: Replace
"your-tenant-id-here"with your actual Azure AD tenant ID - π Choose Contract Type: Update
ContractTypebased on your Azure agreement:"EnterpriseAgreement"- For EA customers"MicrosoftCustomerAgreement"- For MCA customers"CloudSolutionProvider"- For CSP customers"MicrosoftEntraIDTenants"- For Entra ID only assessments
- π Set Default Region: Update
DefaultRegionto your primary Azure region (e.g.,"eastus","westeurope","southeastasia") - π― Select Design Areas: Set to
trueonly the design areas you want to assess:- Start with
"Billing","IAM", and"ResourceOrganization"for initial assessments - Add
"Governance"and"Security"for compliance evaluations - Include
"Network"for connectivity assessments (may take longer) - Enable
"Management"and"DevOps"for operational maturity assessments
- Start with
# Navigate to project root
cd C:\path\to\LandingZoneAssessment-Automate
# Run the assessment
.\scripts\Main.ps1Open web/index.html in your browser to explore the interactive dashboard.
-
π Authentication & Setup
- Validates tenant access and authentication
- Installs/imports required PowerShell modules
- Sets up global context and caching
-
π Configuration Loading
- Reads assessment configuration from
config.json - Loads the Azure Landing Zone checklist
- Applies any manual exceptions from
exceptions.json
- Reads assessment configuration from
-
π Data Collection
- Queries Azure Resource Graph for infrastructure data
- Retrieves Microsoft Entra ID configuration
- Caches all data in global variables for performance
-
π§ͺ Assessment Execution
- Evaluates each enabled design area
- Applies automated logic for compliance checking
- Records detailed findings and evidence
-
π Report Generation
- Creates structured JSON report with all findings
- Generates interactive HTML dashboard
- Produces execution logs and error reports
| Design Area | Key Focus | Automation Level |
|---|---|---|
| π° Billing & Entra ID | Cost management, tenant configuration | π’ Fully Automated |
| π Identity & Access | RBAC, MFA, conditional access | π‘ Mostly Automated |
| π Resource Organization | Management groups, subscriptions, naming | π’ Fully Automated |
| π Network Topology | VNets, connectivity, security | π‘ Mostly Automated |
| βοΈ Governance | Policies, compliance, blueprints | π’ Fully Automated |
| π‘οΈ Security | Security Center, Key Vault, encryption | π‘ Mostly Automated |
| π§ Platform Automation | DevOps, CI/CD, automation | π Manual Review Required |
| π Management | Monitoring, logging, alerting | π‘ Mostly Automated |
The shared/config.json file controls the assessment scope and behavior:
{
"TenantId": "{YOUR_TENANT_ID}",
"DefaultSubscriptionId": "",
"DefaultRegion": "eastus",
"ContractType": "EnterpriseAgreement",
"AlzChecklist": "alz_checklist.en.json",
"DesignAreas": {
"Billing": true,
"IAM": true,
"ResourceOrganization": true,
"Network": false,
"Governance": true,
"Security": true,
"DevOps": true,
"Management": true
}
}| Field | Required | Description | Valid Values |
|---|---|---|---|
TenantId |
β Yes | Your Azure AD tenant ID | GUID format |
DefaultSubscriptionId |
β No | Default subscription for evaluation | GUID or empty string |
DefaultRegion |
β Yes | Primary Azure region for regional assessments | Azure region name (e.g., eastus, westeurope) |
ContractType |
β Yes | Your Azure agreement type | EnterpriseAgreement, MicrosoftCustomerAgreement, CloudSolutionProvider, MicrosoftEntraIDTenants |
AlzChecklist |
β Yes | Assessment checklist file | alz_checklist.en.json |
DesignAreas |
β Yes | Which areas to assess | Object with boolean values |
Billing: Cost management and Entra ID tenant assessmentIAM: Identity and Access Management evaluationResourceOrganization: Management groups, subscriptions, and naming conventionsNetwork: Network topology, connectivity, and securityGovernance: Azure Policy, compliance, and governance frameworksSecurity: Security Center, encryption, and security best practicesDevOps: Platform automation and DevOps practicesManagement: Monitoring, logging, and operational management
The assessment supports manual overrides through the shared/exceptions.json file, allowing you to customize results for specific organizational requirements or constraints.
Edit shared/exceptions.json to override specific assessment results. Each exception must have newStatus and at least one of id or guid:
{
"exceptions": [
{
"id": "E01.01",
"newStatus": "Implemented",
"justification": "Organization uses third-party policy management tool"
},
{
"guid": "70c15989-c726-42c7-b0d3-24b7375b9201",
"newStatus": "NotApplicable",
"justification": "Single-tenant environment; multi-tenant not required"
},
{
"id": "B03.04",
"guid": "abc12345-6789-0abc-def0-123456789abc",
"newStatus": "Implemented",
"justification": "MFA enforced through federated identity provider"
}
]
}Tip: Matching by
guidis more stable across checklist versions. Theguidnever changes, whileidmay shift if items are reordered.
The modern architecture uses standardized status enums:
| Status | Description | Use Case |
|---|---|---|
Implemented |
β Requirement is fully implemented | Compliant configurations |
PartiallyImplemented |
π‘ Requirement is partially met | Partial compliance scenarios |
NotImplemented |
β Requirement is not implemented | Non-compliant configurations |
NotApplicable |
βͺ Requirement doesn't apply | Organizational exceptions |
ManualVerificationRequired |
π Manual review needed | Complex scenarios requiring human judgment |
Unknown |
β Status cannot be determined | Insufficient data or permissions |
Error |
π¨ Assessment failed | Technical errors during evaluation |
- Assessment Execution: Initial automated evaluation runs
- Validation: Exception entries are validated (must have
newStatus+idorguid; invalid entries are skipped with warnings) - Matching: Items are matched by
guidfirst (stable), then byidas fallback - Status Override: Matching items get updated status
- Dashboard Integration: Exceptions table shows original vs. overridden status with justification
- Audit Trail: All changes are logged for transparency
The assessment generates a comprehensive web dashboard (web/index.html) with multiple visualization components:
- Status Distribution Pie Chart: Visual breakdown of compliance status
- Design Area Radar Chart: Progress visualization across all areas
- Trend Analysis: Historical comparison (when available)
- Assessment Details: Complete results grouped by design area
- Error Log: Technical issues and troubleshooting information
- Exceptions Table: Manual overrides with before/after status
- Filtering & Sorting: Dynamic table manipulation
- Search Functionality: Quick item location
- Export Capabilities: Data export for further analysis
- Responsive Design: Works on desktop and mobile devices
- Keyboard Navigation: Full keyboard accessibility
- Screen Reader Support: ARIA labels and semantic markup
- High Contrast Mode: Better visibility for accessibility needs
- Print-Friendly: Optimized for printing reports
- Operating System: Windows 10/11, Windows Server 2016+, or cross-platform with PowerShell Core
- PowerShell: Version 5.1 (Windows PowerShell) or 7.x (PowerShell Core)
- Memory: Minimum 4GB RAM (8GB recommended for large tenants)
- Storage: 500MB free space for reports and logs
- Network: Internet connectivity for Azure API access
| Service | Minimum Role | Recommended Role | Purpose |
|---|---|---|---|
| Azure Subscription(s) | Reader | Reader | Resource inventory and configuration |
| Microsoft Entra ID | Directory Readers | Global Reader | Identity and access assessment |
| Azure Billing | Billing Reader | Cost Management Reader | Cost and billing analysis |
| Azure Policy | Reader | Policy Reader | Governance and compliance evaluation |
This project uses a modern, performance-optimized approach to PowerShell module management:
- Az Meta-Module: Single installation of the complete Azure PowerShell suite
- Selective Import: Only loads specific sub-modules actually needed
- Microsoft Graph: Individual modules for specific Graph API functionality
- Faster Startup: Reduced module loading time by 60-80%
- Lower Memory Usage: Only required modules in memory
- Better Reliability: Reduced module conflicts and version issues
- Easier Maintenance: Simplified dependency management
The assessment automatically handles module installation:
# Core Azure modules (installed as meta-module)
Install-Module -Name Az -Scope CurrentUser -Force -AllowClobber
# Microsoft Graph modules (individual installation)
$GraphModules = @(
'Microsoft.Graph.Authentication',
'Microsoft.Graph.Identity.DirectoryManagement',
'Microsoft.Graph.Users',
'Microsoft.Graph.Groups',
'Microsoft.Graph.Applications',
'Microsoft.Graph.Identity.Governance',
'Microsoft.Graph.Identity.SignIns'
)Only these Azure sub-modules are imported for optimal performance:
Az.Accounts- Authentication and context managementAz.Resources- Resource management and Azure Resource GraphAz.Monitor- Monitoring and diagnosticsAz.Billing- Cost management and billing APIsAz.Network- Virtual networks and connectivityAz.Storage- Storage account managementAz.Sql- SQL database servicesAz.KeyVault- Key Vault and secrets managementAz.Websites- App Service and web applications
"Cmdlet not recognized" errors
# Symptoms: Get-AzStorageAccount: The term 'Get-AzStorageAccount' is not recognized
# Solution 1: Check if Az module is installed
Get-Module Az -ListAvailable
# Solution 2: Install missing module
Install-Module -Name Az -Scope CurrentUser -Force -AllowClobber
# Solution 3: Restart PowerShell and retryAssembly conflicts with Microsoft Graph modules
# Symptoms: Assembly loading warnings or Graph cmdlet failures
# Solution: Fresh PowerShell session
1. Close all PowerShell windows
2. Start new PowerShell session
3. Run assessment directly without manual imports"Insufficient privileges" errors
# Check current context
Get-AzContext
# Verify tenant ID matches config.json
# Ensure account has required permissionsCross-tenant authentication errors
# The assessment enforces tenant isolation
# Verify TenantId in config.json is correct
# Use Connect-AzAccount -Tenant <TenantId> if neededSlow execution times
- Ensure only required modules are imported (automatic)
- Use fresh PowerShell session for best performance
- Consider excluding Network design area for initial runs
- Check available memory (8GB+ recommended for large tenants)
Enable detailed logging by running:
# Set debug preference
$DebugPreference = "Continue"
# Run assessment with verbose output
.\scripts\Main.ps1 -Verbose
# Check logs in logs/ directory- Check Logs: Review files in
logs/directory - Error Reports: Check
reports/ErrorLog.json - Debug Functions: Use utilities in
Debug/DebugFunctions.ps1 - PowerShell Transcripts: Execution logs saved automatically
If the assessment gets stuck or fails completely:
# 1. Stop any running processes
Stop-Process -Name "pwsh" -Force
# 2. Clear PowerShell module cache
Remove-Module -Name Az* -Force -ErrorAction SilentlyContinue
Remove-Module -Name Microsoft.Graph* -Force -ErrorAction SilentlyContinue
# 3. Start fresh session and retryThis project implements several advanced PowerShell patterns for enterprise-grade reliability:
# Global data caching for performance
$global:AzData = @{ Resources = @(); Subscriptions = @(); }
$global:GraphData = @{ Users = @(); Groups = @(); }
$global:TenantId = "tenant-scope-enforcement"# Standardized error logging across all modules
Write-ErrorLog -QuestionID $item.id -QuestionText $item.text
-FunctionName $MyInvocation.MyCommand
-ErrorMessage $_.Exception.Message# Enum-based status for type safety
enum Status {
Implemented; PartiallyImplemented; NotImplemented;
Unknown; ManualVerificationRequired; NotApplicable;
NotDeveloped; Error
}# Consistent result structure across all assessments
$result = Set-EvaluationResultObject -status $status.ToString()
-estimatedPercentageApplied $percentage
-checklistItem $item
-rawData $evidence- Tenant Isolation: Strict tenant scoping prevents cross-tenant data access
- Context Enforcement: All operations validate tenant context
- Minimal Permissions: Uses least-privilege access patterns
- Audit Logging: Complete execution audit trail
- Error Sanitization: Sensitive data removed from error logs
This project is licensed under the MIT License - see the LICENSE file for details.
We welcome contributions! Here's how to get started:
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Follow the architecture patterns described above
- Add tests for new functionality
- Update documentation as needed
- Submit a pull request
- Follow PowerShell best practices and existing code patterns
- Use the shared context pattern for data access
- Implement proper error handling with
Write-ErrorLog - Use enum status values for consistency
- Add appropriate documentation and examples
- Test with multiple tenant configurations
- Azure Landing Zone Team for the foundational framework
- Microsoft PowerShell Team for excellent tooling
- Azure Resource Graph for efficient resource querying
- Microsoft Graph for comprehensive identity data access
- Azure Landing Zone Documentation
- Azure PowerShell Documentation
- Microsoft Graph PowerShell SDK
- Azure Resource Graph Documentation
Last updated: 2025-06-26 | Version: 2.0 (Modernized Architecture)

