How to connect an Express app with Azure DB for PostgreSQL using Entra ID?

Shobhit 5 Reputation points
2024-10-14T06:32:03.3633333+00:00

We are trying to connect to our DB using Sequelize with the help of Entra ID and token as a password.

Is there any better way where we don't have to reset our DB connection every hour?

Currently we are using the API to get new token every 55 minutes and use it as password for DB connection which resets our DB connection

Microsoft Security Microsoft Entra Microsoft Entra ID
{count} vote

1 answer

Sort by: Most helpful
  1. James Hamil 27,211 Reputation points Microsoft Employee Moderator
    2024-10-21T22:56:35.99+00:00

    Hi @Shobhit , this document does a good job detailing possible solutions. You can also configure Microsoft Entra ID access for authentication with Azure Database for PostgreSQL flexible server: https://learn.microsoft.com/en-us/azure/postgresql/flexible-server/how-to-configure-sign-in-azure-ad-authentication

    Please let me know if you have any questions and I can help you further.

    If this answer helps you please mark "Accept Answer" so other users can reference it.

    Thank you,

    James

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.