A comprehensive Python CLI tool for bulk server migration from on-premises to Azure using Azure Migrate and Site Recovery. Features live Azure integration with intelligent validation and project matching.
- ποΈ Two-Layer Validation: Landing Zone (project-level) and Servers (machine-level) validation
- π§ Intelligent Validation: Automatic server-to-project matching with discovery integration
- βοΈ Live Azure Integration: Real-time validation against Azure APIs
- π Rich Reporting: Comprehensive validation results with detailed insights
- βοΈ Configuration-Driven: Flexible validation profiles and customizable rules
- π Secure Authentication: Multiple auth methods (Azure CLI, Service Principal, Managed Identity)
- π Progress Tracking: Real-time validation progress with detailed status updates
- Python: 3.9 or higher
- Azure Access: Valid Azure credentials with appropriate permissions
- Network: Outbound HTTPS access to Azure APIs
- Permissions: Minimum Reader on subscription, Contributor on target resources
# Clone the repository
git clone https://github.com/your-org/azmig_tool_assistant.git
cd azmig_tool_assistant
# Create virtual environment
python -m venv .venv
.venv\Scripts\activate # Windows
source .venv/bin/activate # Linux/Mac
# Install dependencies
pip install -r requirements.txt
# Install the tool
pip install -e .# Interactive wizard (recommended for first-time users)
azmig
# Direct validation with Excel file
azmig validate --excel-file migration_servers.xlsx
# Landing zone validation with CSV
azmig validate --csv-file migrate_projects.csv --type landing-zone
# Use specific validation profile
azmig validate --excel-file servers.xlsx --profile quickRequired fields for Azure Migrate project validation:
| Field | Description | Example |
|---|---|---|
| migrate_project_name | Azure Migrate project name | MyMigrationProject |
| migrate_resource_group | Resource group containing project | rg-migration |
| migrate_project_subscription | Subscription ID | 12345678-1234-5678-9012-123456789012 |
| region | Target Azure region | East US |
| appliance_name | Azure Migrate appliance name | MigrationAppliance01 |
Required columns for machine-level validation:
| Column | Description | Example |
|---|---|---|
| Target Machine Name | Server name in target environment | web-server-01 |
| Target Region | Target Azure region | East US |
| Target Subscription | Target subscription ID | 12345678-1234-5678-9012-123456789012 |
| Target RG | Target resource group | rg-production |
| Target Vnet | Target virtual network | vnet-prod |
| Target Subnet | Target subnet | subnet-web |
| Target Machine Sku | Target VM SKU | Standard_D4s_v3 |
| Target Disk Type | Target disk type | Premium_LRS |
# Active validation profile
active_profile: "default"
# Global settings
global:
fail_fast: false # Stop on first validation failure
parallel_execution: true # Run validations concurrently
timeout_seconds: 300 # API call timeout
# Landing zone validations
landing_zone:
access_validation:
enabled: true
checks:
migrate_project_rbac: {enabled: true}
recovery_vault_rbac: {enabled: true}
appliance_health: {enabled: true}
storage_cache: {enabled: true, auto_create_if_missing: false}
quota_validation: {enabled: true}
# Server validations
servers:
region_validation: {enabled: true}
resource_group_validation: {enabled: true}
vnet_subnet_validation: {enabled: true}
vm_sku_validation: {enabled: true}
disk_type_validation: {enabled: true}
discovery_validation: {enabled: true}
rbac_validation: {enabled: true}
# Validation profiles
profiles:
quick:
overrides:
servers.rbac_validation.enabled: false
servers.discovery_validation.enabled: false
full:
# All validations enabled (default)
rbac_only:
overrides:
servers.region_validation.enabled: false
servers.vnet_subnet_validation.enabled: false# Login with Azure CLI
az login
# Verify access
az account show
# Run validation
azmig validate --excel-file servers.xlsx# Set environment variables
export AZURE_CLIENT_ID="your-client-id"
export AZURE_CLIENT_SECRET="your-client-secret"
export AZURE_TENANT_ID="your-tenant-id"
# Run validation
azmig validate --excel-file servers.xlsx --auth-method service_principal# On Azure VM with managed identity
azmig validate --excel-file servers.xlsx --auth-method managed_identityποΈ Landing Zone Validation Summary
βββββββββββββββββββββββ¬βββββββββ¬βββββββββββββββββββββββββ
β Project Name β Status β Issues β
βββββββββββββββββββββββΌβββββββββΌβββββββββββββββββββββββββ€
β MigrationProject01 β β
Readyβ 0 issues β
β MigrationProject02 β β οΈ Issuesβ Missing cache storage β
β MigrationProject03 β β Failedβ Insufficient quotas β
βββββββββββββββββββββββ΄βββββββββ΄βββββββββββββββββββββββββ
π₯οΈ Servers Validation Summary
βββββββββββββββββββ¬βββββββββββββββ¬ββββββββββββββ¬βββββββββ
β Machine Name β Target Regionβ Validations β Status β
βββββββββββββββββββΌβββββββββββββββΌββββββββββββββΌβββββββββ€
β web-server-01 β East US β 7β
0β β β
Readyβ
β app-server-02 β West US 2 β 6β
1β β β οΈ Issuesβ
β db-server-03 β Central US β 4β
3β β β Failedβ
βββββββββββββββββββ΄βββββββββββββββ΄ββββββββββββββ΄βββββββββ
π§ Intelligent Validation Summary
βββββββββββββββββββββββ¬ββββββββ¬βββββββββ
β Metric β Count β Status β
βββββββββββββββββββββββΌββββββββΌβββββββββ€
β Total Servers β 5 β β
β Project Matches β 4 β 4/5 β
β Discovered Machines β 3 β 3/5 β
β Migration Ready β 3 β 3/5 β
βββββββββββββββββββββββ΄ββββββββ΄βββββββββ
- β Access Validation: RBAC permissions for Azure Migrate and Site Recovery
- β Appliance Health: Azure Migrate appliance status and connectivity
- β Storage Cache: Cache storage account validation and auto-creation
- β Quota Validation: vCPU and resource quotas in target regions
- β Region Validation: Target Azure region availability
- β Resource Group: Target resource group existence and access
- β Network Validation: VNet and subnet configuration
- β VM SKU Validation: Target VM SKU availability and compatibility
- β Disk Validation: Disk type and configuration validation
- β Discovery Validation: Machine discovery status in Azure Migrate
- β RBAC Validation: Machine-specific access permissions
- π§ Project Matching: Automatic server-to-project association
- π§ Discovery Integration: Live Azure Migrate discovery status
- π§ Cross-Subscription: Handle complex enterprise scenarios
- π§ Enhanced Reporting: Detailed insights and recommendations
azmig [OPTIONS] COMMAND [ARGS]...
Options:
--auth-method [azure_cli|service_principal|managed_identity]
Azure authentication method
--profile TEXT Validation profile (default, quick, full, rbac_only)
--non-interactive Run without interactive prompts
--debug Enable debug logging
--help Show help message# Validate with Excel file (servers)
azmig validate --excel-file FILE [--profile PROFILE]
# Validate with CSV file (landing zone)
azmig validate --csv-file FILE --type landing-zone
# Validate with JSON file (landing zone)
azmig validate --json-file FILE --type landing-zone
# Intelligent validation (combines both layers)
azmig validate --excel-file FILE --intelligent
# Custom validation config
azmig validate --excel-file FILE --config custom_config.yaml# Launch interactive wizard
azmig
# Launch with specific authentication
azmig --auth-method service_principalazmig_tool/
βββ core/ # Core business logic and models
βββ interface/ # CLI, wizard, and user interaction
βββ utils/ # Authentication utilities
βββ management/ # Project and template management
βββ config/ # Configuration parsing and validation
βββ validators/ # Validation engine with core validators and wrappers
β βββ core/ # Individual resource validators (region, vnet, vmsku, etc.)
β βββ wrappers/ # Orchestration wrappers (landing zone, servers, intelligent)
βββ clients/ # Azure API clients (Azure Migrate, Resource Manager)
βββ base/ # Base interfaces and contracts
# Issue: "Authentication failed"
# Solution: Re-login with Azure CLI
az login --tenant YOUR_TENANT_ID
# Issue: "Insufficient permissions"
# Solution: Ensure user has required roles:
# - Reader on subscription
# - Contributor on target resource groups# Issue: "Resource not found"
# Solution: Verify resource names and subscription access
# Issue: "Quota exceeded"
# Solution: Request quota increase in Azure portal
# Issue: "Network configuration invalid"
# Solution: Verify VNet/subnet names and regions match# Issue: Slow validation
# Solution: Use quick profile for faster results
azmig validate --excel-file servers.xlsx --profile quick
# Issue: API throttling
# Solution: Tool automatically retries with backoff- Architecture Guide - Technical architecture and design patterns
- Installation Guide - Detailed installation steps (coming soon)
- User Guide - Complete usage guide (coming soon)
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Documentation: See docs/ folder for detailed guides
- Issues: Report bugs and feature requests on GitHub Issues
- Architecture: See ARCHITECTURE.md for technical details
- v3.0.0: Major architecture refactor with organized folder structure and intelligent validation
- v2.x.x: Enhanced Azure integration and validation profiles
- v1.x.x: Initial release with basic validation capabilities
Made with β€οΈ for Azure Migration Projects