This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Exchange Online | |
@ 3600 IN MX 0 <domain selector>.mail.protection.outlook.com. | |
autodiscover 3600 IN CNAME autodiscover.outlook.com. | |
@ 3600 IN TXT "v=spf1 include:spf.protection.outlook.com -all" | |
; Skype for Business | |
sip 3600 IN CNAME sipdir.online.lync.com. | |
lyncdiscover 3600 IN CNAME webdir.online.lync.com. | |
_sip._tls.<domain name>. 3600 IN SRV 100 1 443 sipdir.online.lync.com. | |
_sipfederationtls._tcp.<domain name>. 3600 IN SRV 100 1 5061 sipfed.online.lync.com. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
az network dns zone export -g <resource group> -n <zone name> -f currentzone.zone |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
az network dns zone import -g <resource group> -n <zone name> -f o365zone.zone |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$servicePrincipalConnection=Get-AutomationConnection -Name "AzureRunAsConnection" | |
$appsecret = Get-AutomationVariable -Name "SPAppSecret" | |
Connect-PnPOnline -AppId $servicePrincipalConnection.ApplicationId -AppSecret $appsecret -Url "https://<tenant>-admin.sharepoint.com" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<AppPermissionRequests AllowAppOnlyPolicy="true"> | |
<AppPermissionRequest Scope="http://sharepoint/content/Tenant" Right="Manage"/> | |
</AppPermissionRequests> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You need to be connected to the tenant admin site and Azure AD | |
$User = Get-AzureADUser -SearchString "[email protected]" | |
Set-PnPUserProfileProperty -Account $user.UserPrincipalName -PropertyName "CellPhone" -Value $user.mobile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param | |
( | |
# give the URL of the site or when to reset for every site the admin url | |
[Parameter(Mandatory=$true)] | |
[string]$url, | |
# Do we need to use the weblogin | |
[Parameter(Mandatory=$false)] | |
[switch] | |
$useweblogin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$sites = Get-SPOSite -Limit All | |
foreach ($site in $sites) | |
{ | |
Write-Output $site.Url | |
Get-SPOUser -Site $site.Url | Where-Object {$_.DisplayName -like "Foreign Principal*"} | Select-Object DisplayName, LoginName | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-SPOUser -Site https://worktogether.sharepoint.com | Where-Object {$_.DisplayName -like "Foreign Principal*"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Remove-AzureADDirectorySetting -ObjectId 2781a6b5-8ffc-46e2-9e59-adbc6248e56a |