Power Platform Application Lifecycle Management Suite
PP-ALM: Automating Power Platform Application Lifecycle Management
Migrating Power Platform solutions across environments used to be one of my biggest headaches. I’d spend hours manually exporting, importing, and configuring solutions—time I could have spent building actual business value. That frustration led me to create PP-ALM, a comprehensive automation suite that streamlines the entire ALM process.
Why I Built This Tool
Every Power Platform developer knows the pain points of manual deployments:
- Tedious repetition of export/import steps
- Inconsistent configurations between environments
- Error-prone manual processes
- No standardized versioning approach
- Difficulty unpacking and managing Canvas App source code
After one particularly painful weekend migration that went sideways, I decided there had to be a better way. PP-ALM was born from the need to make these processes reliable, repeatable, and most importantly, automated.
What PP-ALM Does
PP-ALM is a PowerShell-based automation suite that handles the critical aspects of Power Platform ALM:
1. Automated Solution Management
Automatically export both managed and unmanaged versions of your solutions with a single command:
# Export both managed and unmanaged solutions
.\PP-ALM.ps1
The tool runs these exports in parallel processes to improve performance, significantly reducing the total export time compared to sequential operations.
2. Intelligent Versioning
The tool generates consistent version numbers based on the current date and time, ensuring each build is uniquely identifiable:
# Example of generated version
# 3.25.0109.1423 (Year.Month-Day.Hour-Minute)
This eliminates the “which version is which” confusion that plagues many Power Platform projects and provides clear traceability between builds.
3. Canvas App Source Unpacking
PP-ALM automatically unpacks your Canvas Apps into source code format, enabling:
- Version control in Git
- Code reviews
- Easier team collaboration
- Component reuse
The source code is extracted to a dedicated directory, maintaining a clean separation between the solution files and the editable source code.
4. Environment-Specific Configuration
One of the most powerful features is the automatic creation of deployment settings for different environments:
# Creates dev.json, test.json, and prod.json configuration files
This ensures consistent configurations across your dev, test, and production environments while allowing for environment-specific settings where needed.
5. Connection Reference Management
PP-ALM now includes sophisticated connection reference handling:
{
"Prod": {
"/providers/Microsoft.PowerApps/apis/shared_office365": "CONNECTION_ID_HERE",
"/providers/Microsoft.PowerApps/apis/shared_sharepointonline": "CONNECTION_ID_HERE"
},
"Test": {
"/providers/Microsoft.PowerApps/apis/shared_office365": "CONNECTION_ID_HERE",
"/providers/Microsoft.PowerApps/apis/shared_sharepointonline": "CONNECTION_ID_HERE"
}
}
This feature automatically updates environment-specific connection references, eliminating one of the most common causes of deployment failures.
6. Streamlined Deployment
Deploying to target environments is as simple as:
.\PP-ALM.ps1 -Install -EnvironmentUrl "https://yourenvironment.dynamics.com"
Real-World Benefits
Since implementing PP-ALM in our development process:
- Deployment time reduced by 80%: What used to take hours now completes in minutes
- Zero configuration drift: Our environments stay perfectly in sync
- Eliminated deployment errors: No more “I forgot to update that connection” moments
- Better team collaboration: With source control for Canvas Apps, multiple developers can work in parallel
- Standardized versioning: Everyone knows exactly which version is in which environment
- Improved traceability: Each solution deployment can be traced to a specific build with the timestamp-based versioning
How It Works
PP-ALM follows a structured workflow:
- Verification: Checks for dependencies like Power Platform CLI
- Version Creation: Generates a timestamp-based version number (e.g., 3.25.0311.1430)
- Parallel Export: Simultaneously exports both managed and unmanaged solution packages
- Unpacking: Extracts solution components and Canvas Apps to source format
- Configuration: Creates environment-specific settings files
- Connection Mapping: Updates connection references for each environment
- Deployment: (Optional) Imports the solution into target environments
All of this happens automatically with minimal input required.
Getting Started
Ready to streamline your Power Platform ALM process? Here’s how to get started:
-
Add as a submodule to your repository:
git submodule add https://github.com/c-rw/PP-ALM.git tools/pp-alm git submodule update --init --recursive
-
Create a config folder with a basic config.json:
{ "SolutionName": "YourSolutionName" }
-
Run the script:
.\tools\pp-alm\PP-ALM.ps1
Repository Structure
your-solution-repo/
├── Unmanaged/ # Solution files
├── CanvasAppSrc/ # Canvas app source code
├── config/ # Environment configs
│ ├── config.json # Solution config
│ ├── dev.json # Generated
│ ├── test.json # Generated
│ └── prod.json # Generated
├── tools/
│ └── pp-alm/ # PP-ALM submodule
│ ├── PP-ALM.ps1 # Main script
│ └── Connections.json # Connection references
├── Managed.zip # Generated
├── Unmanaged.zip # Generated
└── README.md
Prerequisites
-
PowerShell 5.1 or higher
-
Power Platform CLI (PAC):
winget install Microsoft.PowerAppsCLI
-
Appropriate permissions to the Power Platform environments
Advanced Features
Parallel Processing
Solutions are exported in parallel processes to improve performance:
- Managed solution export
- Unmanaged solution export
This parallel approach significantly reduces the total time required for exports, especially for large solutions.
Connection Reference Management
Using Connections.json, the script automatically updates connection references in environment-specific configuration files for consistent deployment across environments:
# In Connections.json, define connection IDs for each environment
{
"Prod": {
"/providers/Microsoft.PowerApps/apis/shared_office365": "prod-connection-id"
},
"Test": {
"/providers/Microsoft.PowerApps/apis/shared_office365": "test-connection-id"
}
}
Script Parameters
The script supports various parameters for flexible usage:
Parameter | Description | Default |
---|---|---|
-ConfigPath | Path to config.json | ./config/config.json |
-ConnectionsPath | Path to Connections.json | ./tools/pp-alm/Connections.json |
-EnvironmentUrl | Dynamics 365 environment URL | https://org3babe93d.crm9.dynamics.com |
-Install | Switch to perform solution installation | False |
What’s Next for PP-ALM
I’m constantly improving PP-ALM based on real-world usage and feedback. Future enhancements on the roadmap include:
- Integration with Azure DevOps pipelines for CI/CD
- Support for solution component filtering
- Automated testing integration
- Enhanced environment variable handling
- Multi-solution dependency management
- Advanced logging and telemetry
Conclusion
If you’re tired of the manual labor involved in Power Platform deployments, give PP-ALM a try. It’s transformed how I manage Power Platform solutions, and I believe it can do the same for you.
The tool is open source and available on GitHub under the Apache 2.0 license. Contributions, feedback, and feature requests are always welcome!