Comments on: Using the Microsoft Graph SDK for PowerShell with Azure Automation https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/ Practical Office 365 News, Tips, and Tutorials Mon, 20 Nov 2023 12:01:15 +0000 hourly 1 https://wordpress.org/?v=6.3.2 By: Tony Redmond https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-281519 Mon, 20 Nov 2023 12:01:15 +0000 https://practical365.com/?p=55223#comment-281519 In reply to Henrik.

I just noticed the update!

]]>
By: Henrik https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-281517 Mon, 20 Nov 2023 11:56:06 +0000 https://practical365.com/?p=55223#comment-281517 In reply to Tony Redmond.

AHA! Three days ago Microsoft released 2.9.1 where they apparently fixed the bug with login for Managed Identity! When I update to that version the script works again! 🙂

]]>
By: Henrik https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-281516 Mon, 20 Nov 2023 11:42:01 +0000 https://practical365.com/?p=55223#comment-281516 In reply to Tony Redmond.

Hi Tony! 🙂 I have the same problem here. A runbook with Graph Auth module 2.7.0 works as it should in dev tenant. When I moved it to prod tenant the module installed became 2.9.0. The exact same code will not auth with 2.9.0 that auths with 2.7.0. Was there a bug introduced in 2.9.0 that causes it to fail with Managed Identity auth? Gaahhh!

]]>
By: Tony Redmond https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-280708 Tue, 14 Nov 2023 09:56:14 +0000 https://practical365.com/?p=55223#comment-280708 In reply to Justin Nobles.

Do you normally address people by their surname?

In any case, have you read the other articles published here about using managed identities with different modules?

But the first thing I would do is update the resource modules in the Azure Automation account to make sure that you’re using the latest versions. https://practical365.com/update-graph-sdk-azure-automation/

]]>
By: Justin Nobles https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-280706 Tue, 14 Nov 2023 09:35:18 +0000 https://practical365.com/?p=55223#comment-280706 In reply to Tony Redmond.

Hi Redmond,
thanks for the great article. Have you found the time to explore the use of managed identities?
I have tried myself but get stuck with connection issues:

I receive the following error msg when solely running “connect-mggraph -Identity” inside of an Azure Runbook:

ManagedIdentityCredential authentication failed: Could not load file or assembly ‘System.Memory.Data, Version=1.0.2.0, Culture=neutral, PublicKeyToken=************’. The system cannot find the file specified.
See the troubleshooting guide for more information. https://aka.ms/azsdk/net/identity/managedidentitycredential/troubleshoot

Haven’t found a way to work around this yet. Any suggestions?

]]>
By: Anders https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-242621 Sun, 04 Sep 2022 17:45:41 +0000 https://practical365.com/?p=55223#comment-242621 In reply to Liam O Neill.

I am here looking for the same thing! Been breaking it down step by step. Haven’t been able to pull it off yet though.

]]>
By: Imen https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-241499 Thu, 04 Aug 2022 14:17:54 +0000 https://practical365.com/?p=55223#comment-241499 Hi Tony,
Excellent article!
We look forward to your article covering the use of managed identities + Graph Powershell + Azure Automation.
No resources in the Web covering that.

]]>
By: Ernie Shah https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-240296 Sat, 09 Jul 2022 18:51:40 +0000 https://practical365.com/?p=55223#comment-240296 This is an excellent and well-written article. Thanks for the tremendous help this provided to get my runbook script which used the command Get-MgSubscribedSku to work.

]]>
By: Tony Redmond https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-240265 Fri, 08 Jul 2022 09:08:26 +0000 https://practical365.com/?p=55223#comment-240265 In reply to Liam O Neill.

I have played with managed identities and it’s one of the topics I want to cover, once I get some time to focus on it.

]]>
By: Liam O Neill https://practical365.com/microsoft-graph-sdk-powershell-azure-automation/#comment-240263 Fri, 08 Jul 2022 07:05:47 +0000 https://practical365.com/?p=55223#comment-240263 Hi Tony

Very interesting article – I’ve been looking at Azure Automation and system assigned Managed Identities to update a SharePoint Online List. Just wondering if you have tried anything like this as the Managed Identity Roles available such as Contributor I think refer to resources in Azure and not eg SharePoint in Office365?

]]>