Deploying a SharePoint application to a single site collection, rather than to the whole tenant, is achievable with SharePoint Online through Site Collection App Catalogs. Here’s a step-by-step guide on how to do it:
Before you proceed, make sure you have the necessary SharePoint Admin role or greater in your Microsoft 365 tenant and that the Calendar Overlay app has already been added to the tenant app catalog.
Step 1: Enable Site Collection App Catalog
First, you need to enable the Site Collection App Catalog for the specific site. To do this, you can use SharePoint Online Management Shell or PowerShell with the SharePoint Online Management Shell module loaded.
Here is an example using PowerShell:
# Connect to SharePoint Online
Connect-SPOService -url https://your-domain-admin.sharepoint.com
# Enable the Site Collection App Catalog
Add-SPOSiteCollectionAppCatalog -Site https://your-domain.sharepoint.com/sites/YourSiteCollection
Step 2: Upload the App to the App Catalog
- Navigate to your Tenant App Catalog, select the Calendar Overlay app in the list of apps, and click Download to download the app to your computer.
- Click on ‘Site Contents’ from the gear icon in the top right, then select ‘Apps for SharePoint’ in the list.
- Select ‘Upload’ and choose the .cab file you downloaded in Step 1, then select ‘OK’.
- Once the app is uploaded, the deployment dialog will load. Make sure to deselect the ‘Make this solution available to all sites in the organization’ option and then select ‘Deploy’.
- Now select the settings gear in the top right and select ‘Add an app’.
- You will see the Calendar Overlay app in the list of available apps you can add. Select ‘Add’ from the app card.
- The app is now available for use in this site collection. You can now edit any page to add the web part from the gallery.
Please note that deploying an application to a specific site collection restricts its availability to that specific site collection only. Users from other site collections won’t be able to see or use the application.