Solution Deployment - A Guide to Power Platform Pipelines
- Najm-us-saher Farooque
- Sep 18, 2024
- 7 min read
If you are an experienced developer in Power Platform or Dynamics CRM, you’re likely familiar with how Azure Pipelines can be used to automate solution deployment. Azure Pipelines allow you to build, merge, test, and deploy your solutions, fully automating the process. However, mastering Azure Pipelines requires a deep understanding of its features.
As Microsoft continues to promote low-code/no-code solutions, they decided to bring similar capabilities directly into Power Platform, making it easier for anyone to deploy solutions with minimal technical expertise. This led to the introduction of Pipelines in Power Platform.
Let’s delve into Power Platform Pipelines and explore their full potential. So, let’s dive in!
What are the Power Platform Pipelines
Power Platform Pipelines are a built-in feature designed to simplify the deployment of solutions across different environments (such as development, testing, and production) without requiring advanced DevOps knowledge. The key aim is to make application lifecycle management (ALM) accessible for all users, from beginners to seasoned developers. With this feature, even users with minimal coding experience can automate solution deployment seamlessly within the Power Platform ecosystem.
Key Features of Power Platform Pipelines:
Low-Code/No-Code Automation: Pipelines in Power Platform are designed with ease of use in mind. You can deploy solutions across environments without writing complex scripts, making ALM processes more accessible to non-developers.
Pre-Configured Templates: Microsoft provides ready-to-use pipeline templates for common deployment tasks, removing the need for custom configurations and saving you time when setting up deployments.
Visual Interface: The pipelines feature includes a simple, intuitive interface that allows you to visualize the entire deployment process. This ensures that users can follow the flow from one stage to the next without diving into complex configurations.
Environment Promotion: With pipelines, you can easily promote solutions from development to test and then to production environments. This makes it simple to manage your app versions and control which solutions are live and stable.
Secure and Controlled Deployments: Power Platform Pipelines come with built-in controls to ensure that only authorized users can deploy solutions. This adds a layer of governance, making sure the right solutions are promoted at the right time.
Version Control and History: You can track and review previous deployments, ensuring full visibility into what has been deployed, by whom, and when. This allows for easy rollback if needed.
Personal vs. Custom Pipelines
Personal Pipelines:
Personal Pipelines are designed for individual users who may not have much technical expertise but still want to build and deploy solutions. These pipelines are easy to set up and use, allowing you to deploy your apps or workflows from one environment (like development) to another (like production) with minimal effort.
Custom Pipelines:
Custom Pipelines are more advanced and flexible, allowing for customization based on specific business needs. These are typically used by developers or admins who want more control over how the deployment process works. With custom pipelines, you can adjust different stages, add security checks, or integrate other tools into the pipeline.
Configuring Personal Pipelines
Personal Pipelines are pipelines you can create directly from the solution, similar to the full pipeline experience.
Let's create a demo solution to demonstrate how Personal Pipelines work. We will call it "Pipeline Solution"
There are a few prerequisites for setting up Personal Pipelines:
All target environments must be enabled as Managed Environments. To do this, go to the Admin center, select the environment, and click "Enable as Managed Environment."
Personal Pipelines can configure up to three environments: one Host and two Targets.
To deploy, click on your solution and then the "Deploy" button. This will take you to the Pipelines page.
Next, click "Create Pipeline," choose the target environment, and then click "Save."
Since you can deploy to two target environments, to add another target environment, click on "Add Stage" in the command bar.
This will open the same window as when creating a pipeline. Name the stage and select the target environment.
The stage will then be added to the pipeline. However, you must be the owner of the pipeline to add a stage.
To deploy the solution, click the "Deploy here" button in the stage. You can choose to deploy immediately or schedule it for later. In this case, we are deploying immediately by selecting "Now." Then, click "Next."
Click the "Deploy Here" button in the stage to deploy the solution. You can choose to deploy immediately or schedule it for later. For immediate deployment, select "Now" and then click "Next"
A notable feature is that Copilot automatically generates deployment notes in the Summary section, listing every component in the solution. If you prefer not to use this feature, you can disable it by going to "Manage Pipeline" and selecting "Disabled" for the AI deployment notes button.
Click "Deploy" to begin the deployment.
You can monitor the pipeline, which will display the version number.
Once the pipeline completes, you can view the solution version and deployment date. Navigate to your environment to confirm that the solution has been deployed as a Managed Solution.
You can repeat this process for other target environments.
Click on "Managed Pipelines" to view the Pipeline Dashboard, run history and Solution Artifacts.
Simple and Easy! So, here is an overview of Personal Pipelines:
Pros:
Easy to start
Imports Managed Solutions following Microsoft ALM guidelines
Keeps a history of solution runs
Cons:
Cannot include approval processes
Limited to three environments
Not shareable with others
AI Deployment notes are only available in the United States region
Cannot redeploy older solutions
Configuring Custom Pipelines
As we’ve mentioned, custom pipelines offer more advanced features. They provide the flexibility to customize and refine how your apps and workflows are deployed, making them ideal for larger teams or organizations with more complex needs.
Prerequisites for Custom Pipelines:
Four environments are recommended, but you can use as few as needed.
You must have a Power Platform administrator or Dataverse system administrator role to install the pipelines application.
All target environments used in a pipeline must be enabled as Managed Environments.
Microsoft advises keeping the Host environment separate from Development, QA, and Production environments.
Install Power Platform Pipelines App:
Go to the Admin Center.
Select your Host environment.
Navigate to Resources > Dynamics 365 Apps.
Click on Install App.
Scroll down to find and install the Power Platform Pipelines application.
After Installation, you can see the "Deployment Pipeline Configuration" App.
Configure the Pipeline:
Copy the Environment IDs for both Development and Target environments. To do this:
Go to the Admin Center.
Open your environment.
Copy the Environment ID from the Details section.
Go to the "Deployment Pipeline Configuration" app and first set up the environments. Click on "Environments" then select "New" to configure your Development and Target environments.
Name: Enter the name of the environment.
Environment Type: Choose whether the environment is Development or Target.
Environment ID: Enter the Environment ID you copied.
Click "Save," then refresh the form. Make sure the Validation Status shows as "Success."
If you see a "Failed Validation" status with an error saying "Environment is already configured with Pipelines in host environment," it means your environment is set up in another pipeline. Click the "Force Link" button to unlink it from the current pipeline and connect it to this one.
In the same way, configure the Target Environments.
In the left navigation pane, click "Pipelines" then select "New" to create a new deployment pipeline.
Name: Enter a name for your pipeline.
AI Deployment Notes: Turn this on if you want AI-generated deployment notes (available for the US region).
Allow Redeployments of Older Versions: Enable this if you want to allow re-deploying older versions.
In "Linked Development Environments" click the "Add Existing Deployment Environments" button and choose the development environments. The pipeline must have at least one development environment.
In the Deployment Stage, click "New Deployment Stage" and fill in the required properties:
Name: The name of the stage.
Previous Deployment Stage: If you want the solution to deploy to another environment before deploying it to the Production environment, select the Previous Deployment Stage.
Target Deployment Environment: Select the Target Environment.
Pre-Deployment Step Required (optional): This is where you can configure approval processes or pre-deployment steps. You can extend the pipelines for complex processes.
Repeat the previous two steps for each stage you want to add to the pipeline. Just select the stage and add it one by one.
Run the Pipeline:
To run the pipeline for a specific solution, click "Deploy" in the command bar. Then, select the pipeline from the drop-down menu. It will show all the stages you have set up.
Click "Deploy here" to begin the deployment. You can choose to start it right away or schedule it for a later time. After that, click "Next" In the Summary section, deployment notes will be added automatically.
To re-deploy the pipeline, go to the solution history, select the version of the solution you want, and choose the re-deploy option.
What’s Missing and Summary:
Here are some features missing from Power Platform Pipelines:
Limited Customization: Power Platform Pipelines make it easier to deploy solutions, but they don’t offer as much flexibility as tools like Azure DevOps. You have fewer options to customize specific deployment steps or automate tasks, which might not work for more complex business needs.
No Parallel Deployment: Currently, Power Platform Pipelines can’t run multiple deployments at the same time. If your organization works with several environments, this could slow things down when you need to do many deployments at once.
Basic Reporting and Monitoring: The reporting tools built into Power Platform Pipelines are quite simple. There aren’t many options for detailed reports or dashboards to track how successful or unsuccessful deployments are, which can make it harder to improve processes over time.
Limited Scheduling Options: Power Platform Pipelines don’t have advanced scheduling features for automating deployments at specific times. This could be an issue if you want to deploy during non-business hours or at specific times.
Power Platform Pipelines offer a user-friendly way to automate solution deployment, especially for those who prefer low-code/no-code solutions. While they may not match the flexibility of Azure DevOps in all aspects, they provide a valuable toolset for managing deployments within the Power Platform ecosystem. Whether you’re using personal or custom pipelines, these tools can streamline your deployment processes and enhance your overall application lifecycle management.
For a comprehensive and in-depth analysis, please refer to the Microsoft documentation:
Explore Microsoft Documentation on Power Platform Pipelines
Stay tuned for more blog posts!
Commenti