/azure-mysql-managed-identity

Simple Java app running on an Azure VM connecting to Azure SQL for MySQL through VM's managed identity

Primary LanguageJava

Demo for Azure MySQL access from Java with Managed Identity (VM)

  • Create a new Azure SQL for MySQL database
  • Assign an Active Directory admin for the MySQL database
  • Create a new Azure VM and assign identity (system assigned) to the VM
  • Login to the MySQL database as Active Directory admin and Create a new user in MySQL database for the VM
create aaduser vmuser identified by '<managed identity's object id>'