Software services delivering SharePoint, Mobile, and Business Intelligence solutions Understanding and implementing the remote provision pattern in SharePoint 2013 on-premises and O365 web sites Todd Baginski Canviz LLC
WHO IS THIS
Agenda A quick look back in the SharePoint time machine What’s changed? What is remote provisioning? What can I do with it? What patterns can I use? Let’s see some examples and dive into the code! Questions and Answers Discussion
The evolution of SharePoint deployment techniques 2003 Manual Xcopy Site Definitions 2007 WSP Full Trust Declarative Site Definitions Feature Stapling 2010 WSP Full Trust Declarative Sandbox Declarative Web Templates Feature Staling 2013 Full Trust Discouraged Sandbox Deprecated App Stapling Remote Provisioning!
Ch-ch-ch-ch-changes… Full Trust approach discouragedSandbox deprecated CSOM / REST now plays a big role! FTC to CAM – Stop creating content types and site columns declaratively content-types-and-site-columns-declaratively.aspx “Really… just don’t use element xml files to provision content types or site columns in your full trust / farm solutions.”
So, what is Remote Provisioning?
What can I do with it? Provision a variety of components – Team Sites – Branding – Features – Master Pages – Page Layouts – CSS – Content – Web Parts – Lists – List Items – Content Types – Fields – Etc.
Various Patterns Override create sub site link with link to Provider-hosted App – Only used when targeting sub site creation
Pattern 1: Override create sub site link Override create sub site link with link to Provider-hosted App – Only used when targeting sub site creation – Configured in SharePoint admin center – Provider-hosted app uses CSOM/REST APIs to provision sites
Pattern 2: Provider-hosted app Provider-hosted app uses CSOM/REST APIs to provision sites – May be used to create site collections or sub sites – Requires Full Control of tenancy Won’t work in the MS Marketplace
Pattern 3: Windows / Java / IOS applications or Scripts Custom applications / scripts use CSOM/REST APIs to provision sites May be used to create site collections or sub sites Authentication can be a challenge Dev-Ops scenarios
It’s Demo Time! Web API uses Managed CSOM / REST to – Provision root site and sub sites – Provision branding artifacts (Master Page, Images, CSS, JS, Page Layouts) – Create Announcements list and add Announcements – Create Tasks list and add Tasks – Clear and set home page contents – Add and install SP Apps – Add documents to document libraries in SP Apps via App Installed event
Summary The way to deploy code and assets to SharePoint sites has changed many times in the last decade. Remote Provision works best with the new Cloud App Model (CAM) There is more than one pattern you can use to implement Remote Provisioning Microsoft recommends the Remote Provisioning pattern Several code samples and articles are available which makes learning this pattern easy
Helpful Related Resources Self-Service Site Provisioning using Apps for SharePoint 2013 – site-provisioning-using-apps-for-sharepoint-2013.aspx site-provisioning-using-apps-for-sharepoint-2013.aspx Office AMS Samples – Office365 Development Patterns and Practices – – Provisioning.Services.SiteManager – Provisioning.SubSiteCreationApp – Provisioning.SiteCollectionCreation – Branding.* – Branding.DisplayTemplates – Core.DataStorageModels SharePoint Online Solution Pack for branding and provisioning –
Let’s discuss! Questions Answers Discussion
Thank You! Thanks for spending your first session at SharePoint Fest Denver 2014 with me, I hope you enjoyed it and learned a lot! My next session follows this one, it’s all about mobility and SharePoint. How to contact me: Web Site: Blog: