Creating the Artifactory PostgreSQL Database
Supported PostgreSQL Versions
Artifactory supports the following PostgreSQL versions: 9.5 and 9.6 (note that these versions will be EOL in 2021), 10.x, 11.x, 12.x, and 13.x.
Use the commands below to create an Artifactory user and database with appropriate permissions. Modify the relevant values to match your specific environment:
Once you have verified that the script is correct, you need to run it to create the database and proceed with configuring the database.
We recommend providing Artifactory with full privileges on the database.
Configuring Artifactory to use PostgreSQL
Download the JDBC driver corresponding to your PostgreSQL version from the PostgreSQL JDBC Driver Download site and copy the downloaded
Make sure your driver has read permissions for all users.
Adjust the database connection details in the
Storing BLOBs inside PostgreSQL is not recommended
The above recommended configuration keeps all artifact information in PostgreSQL while storing the artifact binary data on the file system (under
While it is possible, to store BLOBs inside PostgreSQL we do not recommended it. This is important because the PostgreSQL driver doesn't support streaming BLOBs with unknown length to the database. Therefore, Artifactory will temporarily save deployed files to the filesystem and only then save the BLOB to the database.
Enabling TLS Encryption
To enable Transport Layer Security (TLS) encryption for PostgreSQL, set the
sslmode property to
verify-full in the
JDBC connector URL.
For example, in the
If you are using old certificates or have an AWS RDS instance that was created before July 2020, you will not have Subject Alternative Name (SAN) enabled. To resolve this issue, you will need to generate a new certificate with SAN.