Created
August 29, 2019 14:51
-
-
Save jsturtevant/b4fbe835b4de4af3e3a74f58563b9ead to your computer and use it in GitHub Desktop.
Add Service Principal to Azure AAD group
This file contains hidden or 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
#https://stackoverflow.com/a/47769755/697126 | |
$spn = Get-AzureADServicePrincipal -SearchString "yourSpName" | |
$group = Get-AzureADGroup -SearchString "yourGroupName" | |
Add-AzureADGroupMember -ObjectId $($group.ObjectId) -RefObjectId $($spn.ObjectId) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment