5 Key Areas Over 40 Minutes
(5 mins)
Why DevOps? Manual deployments = Problems
Prerequisites: Azure DevOps + Power Platform CLI
Repository: Organized folders = Success
(25 mins)
Demo 1: Setup Pipeline + Build Tools
Demo 2: Export & Unpack Solutions
Demo 3: Deploy to Target Environment
(5 mins)
Templates: Download ready-to-use pipeline YAML files
Takeaways: Start simple, automate gradually, secure always
Link to slides: QR code at the end
Questions: Ask now or connect later for follow-up
PowerPlatformClinic.github.io
๐ Enhanced Security & Compliance
โก Better Performance & Scalability
๐ Advanced Branching Strategies
๐ Tenant Independent
๐งช Expand into Automated Testing
๐ No Managed Environments Required
๐ Source Code Visibility
๐ Automated Documentation
โ๏ธ Edit Solutions Between Environments
Before We Start
Client ID:
Tenant ID:
Secret:
Client ID:
Tenant ID:
Secret:
Server URL:
MyPowerPlatformProject/
โโโ solutions/
โ โโโ src/
โ โ โโโ MySolution/
โ โโโ MySolution.zip
โโโ pipelines/
โ โโโ export-solution.yml
โ โโโ build-and-deploy-solution.yml
โโโ documentation/
โโโ README.md
Live Demo: Setting up the export pipeline in Azure DevOps
name: $(TeamProject)_$(BuildDefinitionName)_$(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.r)
variables:
- name: varPowerPlatformSPN
# value: YOUR-OWN-VALUE-HERE
value: Dataverse - Backup
- name: varSolutionName
# value: YOUR-OWN-VALUE-HERE
value: ProjectExpenseLogger
trigger: none
pool:
vmImage: 'windows-latest'
steps:
- checkout: self
persistCredentials: true
clean: true
- task: PowerPlatformToolInstaller@2
inputs:
DefaultVersion: true
AddToolsToPath: true
- task: PowerPlatformSetSolutionVersion@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: '$(varPowerPlatformSPN)'
SolutionName: '$(varSolutionName)'
SolutionVersionNumber: '1.0.0.$(Build.BuildID)'
- task: PowerPlatformExportSolution@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: '$(varPowerPlatformSPN)'
SolutionName: '$(varSolutionName)'
SolutionOutputFile: '$(Build.SourcesDirectory)\solutions\$(varSolutionName)_1.0.0.$(Build.BuildID)_managed.zip'
Managed: true
AsyncOperation: true
MaxAsyncWaitTime: '60'
- task: PowerPlatformExportSolution@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: '$(varPowerPlatformSPN)'
SolutionName: '$(varSolutionName)'
SolutionOutputFile: '$(Build.SourcesDirectory)\solutions\$(varSolutionName)_1.0.0.$(Build.BuildID).zip'
Managed: false
AsyncOperation: true
MaxAsyncWaitTime: '60'
- task: PowerPlatformUnpackSolution@2
inputs:
SolutionInputFile: '$(Build.SourcesDirectory)\solutions\$(varSolutionName)_1.0.0.$(Build.BuildID).zip'
SolutionTargetFolder: '$(Build.SourcesDirectory)\solutions\src\$(varSolutionName)'
SolutionType: 'Both'
- task: PowerShell@2
inputs:
targetType: 'inline'
script: 'pac solution create-settings --solution-zip $(Build.SourcesDirectory)\solutions\$(varSolutionName)_1.0.0.$(Build.BuildID).zip --settings-file $(Build.SourcesDirectory)\solutions\$(varSolutionName)-settings.json'
- task: CmdLine@2
inputs:
script: |
echo commit all changes
git config user.email "$(Build.RequestedForEmail)"
git config user.name "$(Build.RequestedFor)"
git checkout -b main
git add --all
git commit -m "Latest solution changes."
echo push code to new repo
git -c http.extraheader="AUTHORIZATION: bearer $(System.AccessToken)" push origin main
Live Demo: Understanding the solution structure
Live Demo: Deploy the solution
name: $(TeamProject)_$(BuildDefinitionName)_$(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.r)
variables:
- name: varSolutionName
# value: YOUR-OWN-VALUE-HERE
value: FirstPipeline
- name: varPowerPlatformSPN
# value: YOUR-OWN-VALUE-HERE
value: Dataverse - mightora
trigger: none
pool:
vmImage: 'windows-latest'
steps:
- checkout: self
persistCredentials: true
clean: true
- task: PowerPlatformToolInstaller@2
inputs:
DefaultVersion: true
AddToolsToPath: true
- task: PowerPlatformPackSolution@2
inputs:
SolutionSourceFolder: '$(Build.SourcesDirectory)\solutions\src\$(varSolutionName)'
SolutionOutputFile: '$(Build.ArtifactStagingDirectory)\solutions\build\$(varSolutionName).zip'
- task: PowerPlatformImportSolution@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: 'Dataverse - Backup'
Environment: 'https://mightora.crm11.dynamics.com/'
SolutionInputFile: '$(Build.ArtifactStagingDirectory)\solutions\build\$(varSolutionName).zip'
AsyncOperation: true
MaxAsyncWaitTime: '60'
Problem:
Solution export times out
Solution:
AsyncOperation: true
MaxAsyncWaitTime
Problem:
Connections fail in target environment
Solution:
Problem:
Environment-specific values
Solution:
DevOps is a Journey, Not a Destination
You now have the tools to automate your Power Platform solution lifecycle!