Forum Discussion
Damien Calvert
Jul 28, 2017Iron Contributor
Can you create publishing sites with powershell?
Hi,
Is there a way to create a Sharepoint Online publishing site with Powershell?
We have a standard for a publishing site which contains two custom document libraries (templated) and a page layout.
It's really tedious creating 20 or 30 of these.
Thanks
Damien
2 Replies
- Dean_GrossSilver Contributor
one way is to use the PnP powershell cmdlets, create a site, then enable the desired features (publishing Infrastructure and Publishing) in your case, see https://github.com/SharePoint/PnP-PowerShell/blob/master/Documentation/EnablePnPFeature.md
- Yeap, I don't see why not...you have also SPO APIs to create artifacts in SPO so should be able to create Publishing sites with no problems