postgresqlflexible
This is an old revision of the document!
Entra ID Authentication
az login az account get-access-token --resource-type oss-rdbms --output tsv --query accessToken $env:PGPASSWORD='<Access_Token>' psql "host=server.postgres.database.azure.com user=postgres_users dbname=postgres sslmode=require"
-- Display existing Entra principals select * from pg_catalog.pgaadauth_list_principals(false); -- Add Entra principal to the server. -- roleName must match the name of an existing Entra principal select * from pg_catalog.pgaadauth_create_principal(roleName text, isAdmin boolean, isMfa boolean) select * from pg_catalog.pgaadauth_create_principal('postgres_users', false, false)
postgresqlflexible.1742999473.txt.gz · Last modified: 2025/03/26 14:31 by z0hpvk