Table of contents
App deployment is a type of publishing, that allows the dedicated installation of your Solution Package on any SharePoint Online site.
Initial App Deployment
To deploy the solution on target site with App Deployment method you have to follow the steps:
1. Register an App: In Solution Studio on the Publish tab -> App Deployment -> click on the 'Publish' button. In the publish wizard make sure the 'App Deployment' type is selected.
Specify the App title and select the Package version you want to publish.
Final Title of the App will be 'Solution Installer - <App Title>'
Click on the Next button to redirect to the Deployments tab where you can select: Standard Deployment or Selective deployment. The Standard Deployment option is selected by default and it deploys all solution elements in the package to the target site. To use the Selective Deployment option select the second option and click on the Next button.
The Selective deployment wizard appears which displays all solution elements included in the package as a hierarchical checkbox tree. Read more in the Selective Deployment article.
The Summary step includes information about the App title, package version, deployment type with logs of what will be included in the deployment.
2. After the App is registered you can download the App package it in the right panel.
Note: Before you start deploying the App on the target site please ensure the following:
- You have administrative access to the SharePoint Admin Center (it is required for the Step 1 and Step 2 in Maintenance dialog).
- You have appropriate permissions (Site Collection Administrator) on the target site.
- Site Collection App Catalog is enabled for the target site (instead of the tenant-wide App Catalog).
If the Site Collection App Catalog is not enabled, use PowerShell to enable it:
Using the SharePoint Online Management Shell
# Connect to SharePoint Online
Connect-SPOService -Url "https://<tenant>-admin.sharepoint.com"
# Enable the Site Collection App Catalog
Add-SPOSiteCollectionAppCatalog -Site https://<site-url>
or using PnP Powershell
# Connect to SharePoint Onlin
Connect-PnPOnline -Url "https://<tenant>.sharepoint.com/sites/<site-url>" -Interactive -ClientId <client id of your Entra ID Application Registration>
# Enable the Site Collection App Catalog
Add-PnPSiteCollectionAppCatalog -Site "https://<tenant>.sharepoint.com/sites/<site-url>"
Replace <tenant> with your tenant name and <site-url> with the URL of the site where you want to enable the Site Collection App Catalog.
3. Installation: Extract the .sppkg file from the downloaded zip. Upload .sppkg to App Catalog on the target site. After uploading, a dialog will appear. Click on the Deploy button to deploy the App for the specific site collection.
Note: The solution will be deployed only to this site collection and not tenant-wide.
4. On the target site add the App. Go to the Site Contents of the target SharePoint site where you want to deploy the solution and click on New button to add the App. In the list of the available apps choose the App you've added to the App Catalog.
5. Open the Solution Installer hidden list. The Solution Installer list, used to track the deployment process, is hidden. You can access the URL by the following ways:
- In the readme.txt:
<site-url>/Lists/SolutionInstaller_Wine_Seller_App_Deployment/
where <site-url> is a target site URL
- Alternatively, you can open your browser's developer tools (press F12) and locate the full URL for the Solution Installer list.
6. Finalize the deployment: Open Maintenance Page and follow the steps on the Maintenance Dialog:
Note: If 'Open Maintenance Page' it not displayed in first opening try to press CTRL+F5 (twice). This issue may occur due to SharePoint cache problems with custom command actions.
- Step 1 - Trust the skybow App Deployment Connector. This should be done by tenant SharePoint Administrator once per tenant.
- Step 2 - Assign Permissions: To assign Full Control permission in the site collection you can directly click on the button 'Grand Full Control permissions in the site collection'. Or alternatively, you can run the script via PowerShell.
Note for Method 1: This required the delegated 'Site.FullControl.All' permission to be granted in the SharePoint Admin Center. If you get the error 'Access denied' on click on the button you have to approve 'Site.FullControl' permission in SharePoint admin center -> API Access (follow the link on the Maintenace dialog window). Refresh the page (F5) and click on the 'Grand Full Control permissions in this site collection' button. After you assign Full Control permission you can remove access 'Site.FullControl' permission in SharePoint admin center.
Note for Method 2: if you are using PowerShell script to grant Full control permission, please make sure you configure authentication for PnP PowerShell:
https://pnp.github.io/powershell/articles/authentication.html
- Step 3 - Deploy the solution to the site.
When solution is deployed and you can see the deployment logs in the Maintenance dialog window to check whether there are no errors. Also, you can check deployment logs in the Solution Studio in the Publish section under App Deployments.
- Step 4 - Trust additional connectors. If you package contains actions that need to approve specific connectors you have to trust them to finish deployment properly.
Update Deployment
If you make some changes to your solution after the initial deployment, you have to create a new package and then select the deployment definition in the Publish section in solution studio.
Click the Update button to open the wizard that guides you through updating a service. Additionally, you can configure different deployment configurations for Initial and Update deployments when updating skybow App registration. This means every new deployment on this service will use configuration from Initial deployments, while every update will use the configuration from the Update deployments.
This will not automatically update any deployments, you have now 2 options to update them separately:
- Select a deployment in Solution Studio and click on Update in the right panel
- Navigate to Solution Installer hidden list -> open Maintenance page and click on the Update in the Maintenance dialog window. The new version should be recognized.