This blog will demonstrate on how to connect Azure SQL database from Python Function App using managed identity or access token. If you are looking for how to implement it in Windows App Service, you...
Thank you for putting eyes on the code KevinLi. My fault for missing that glaring problem! I changed the MSI_SECRET verbiage. Still unable to get the remote connection.
- NewError:
- FIX: Toggled the "Allow Azure services and resources..." switch under the "Firewalls and Virtual Networks" blade of the SQL server
- Now stuck with this:
- Verified that the SAMI name is part of the correct roles:
- And verified that the SAMI has Contributor role on the SQL resource group.
- The SQL server is in a separate RG than the Azure Function.
- Not sure if this matters
Any other ideas?
Thank you
EDIT:
- SELECT * FROM sys.external_data_sources yields no results for either the SQL db nor the master db...
- I think this is a small bug in MS SQL
- SAMI's are technically from an external provider (AD) therefore should be showing up here...