Skip to content

Azure PostgreSQL#

This topic allows you to connect to an Azure PostgreSQL server from the Azure virtual machine which will act as a storage for Ranger database and Privacera database (Optional).


Before you begin, ensure the following prerequisites are met:

  • Create a privacera_db database in the  Azure PostgreSQL server that can be accessible.

UI Configuration#

  1. Launch PM UI. For more information on how to start PM UI, click here.

  2. In the left navigation of the PM UI, navigate to Setup Environment.

    On the left navigation, Platform and Installation Type is displayed under Setup Environment.

  3. Click Platform and Installation Type to modify the properties. In Select Policy Store, select the Azure database from the dropdown list.

    On the left navigation, the Azure database is displayed under Setup Default Services.

  4. Click the Azure database to modify the properties.

    1. Set External Database Flavour to the Azure database.

    2. Enter the database properties.

    3. Click Next/Save.

  5. To install/update, go to Install in the left navigation, and click Install & Start Services.

CLI Configuration#

  1. SSH to the instance where Privacera is installed.

  2. Run the following command.

    cd ~/privacera/privacera-manage
    cp config/sample-vars/vars.external.db.yml config/custom-vars/
    cp config/sample-vars/vars.external.db.postgres.yml config/custom-vars/
    vi config/custom-vars/vars.external.db.postgres.yml
  3. In this file set values for the following:

    Enter the hostname of the Azure PostgreSQL server, and the name of the database you want to connect to.

    EXTERNAL_DB_NAME: "privacera_db"

    Enter the credentials of the user who has access to the database.


    (Optional) Enter a database name for Privacera Portal, Privacera Ranger, and Privacera Ranger KMS. It is recommended to provide different names for the 3 databases.



  1. Login to Privacera portal.

  2. Go to Access Management > Resource Policies. You should be able to see the Postgres service.