microsoft / MSCloudLoginAssistant

PowerShell Module Handling Authentication to Cloud Services
https://www.powershellgallery.com/packages/MSCloudLoginAssistant/
MIT License
72 stars 47 forks source link

Test-MSCloudLogin cmdlet no longer available #166

Open sdfarquhar opened 7 months ago

sdfarquhar commented 7 months ago

It looks like the "Test-MSCloudLogin" cmdlet was removed from this most recent release (1.1.0)?

andikrueger commented 7 months ago

Please use Connect-M365Tenant as an alternative. As soon as there is a connection present, this will be reused.

sdfarquhar commented 7 months ago

Hi Andi, I have started using this command to test but I still want to point out that in Azure Automations with managed identity this still fails (server timeout) to connect. The only workaround or partial workaround is to do a "connect-exchangeonline" first to establish a connection. This was not the case several weeks ago, so I really believe MS has changed something within the Azure Automation that is causing these connection timeouts. I just tested again with the most current release, 1.1.2, of the MSCloudLoginAssistant and it times out as well unless I pre-connect to Exchange online.

Running just this command causes a server timeout. Appears that the command is waiting for some sort of response but nothing is displayed in Azure Automation

Connect-M365Tenant -Workload ExchangeOnline -TenantID mytenant.onmicrosoft.com -Identity -Verbose -Debug

Running the connect EXO command prior to the above command will allow a successful connection

Connect-ExchangeOnline -ManagedIdentity -Organization mytenant.onmicrosoft.com Connect-M365Tenant -Workload ExchangeOnline -TenantID mytenant.onmicrosoft.com -Identity -Verbose -Debug