pnp / PnP-PowerShell

SharePoint PnP PowerShell CmdLets
https://pnp.github.io/powershell
Other
985 stars 665 forks source link

[BUG] Get-PnPSearchConfiguration not working with on premise tenant admin site #2962

Open gabbsmo opened 3 years ago

gabbsmo commented 3 years ago

Reporting an Issue or Missing Feature

Issue

Expected behavior

Outputs search configuration xml

Actual behavior

"Current site is not a tenant administration site".

In the source it looks like the cmdlet is hardcoded to look for "-admin" in the url. We tried setting up a hostnamed site collection for the tenant admin site but was never successful and settled for "/sites/tenantadmin" as per the example code for definetenantadminsite.ps1.

Steps to reproduce behavior

  1. Define a tenant site https://sharepoint.contoso.com/sites/tenantadmin using definetenantadminsite.ps1
  2. Run Get-PnPSearchConfiguration -Scope Subscription -Path ".\Search.xml"

Which version of the PnP-PowerShell Cmdlets are you using?

What is the version of the Cmdlet module you are running?

3.26.2010.0

How did you install the PnP-PowerShell Cmdlets?