PostgreSQL

ARTIFACTORY: How to configure Artifactory with an external database when using Artifactory Helm Installation

AuthorFullName__c
Bassel Mbariky
articleNumber
000005515
ft:sourceType
Salesforce
FirstPublishedDate
2022-12-21T17:22:08Z
lastModifiedDate
2023-03-09
VersionNumber
5
Artifactory Helm Installation comes bundled with a postgresql database, however, you may want to use your own database instead. In that case, you will need to set the postgresql.enabled: false value and the database section instead for the chart to use the External database.* parameters. Without it, they will be ignored and the chart will use the internal DB, below is an example:
postgresql:
 enabled: false
database:
 type: postgresql
 driver: org.postgresql.Driver
 url: 'jdbc:postgresql://${DB_HOST}:${DB_PORT}/my-artifactory-db'
 user: <DB_USER>
 password: <DB_PASSWORD> 

In case you are using an RDS database, the following values should be used:
postgresql:
 enabled: false
database:
   type: postgresql
    driver: org.postgresql.Driver
    url: "jdbc:postgresql://test.postgres.database.azure.com:5432/artifactorydb"
    username: "artifactory@test"
    password: password
    actualUsername: artifactory@test

The same applies when setting up Xray with PostgreSQL database, But using a different prefix for the DB URL:
postgresql:
 enabled: false
database:
 type: postgresql
 driver: org.postgresql.Driver
 url: 'postgres://${DB_HOST}:${DB_PORT}/xraydb?sslmode=disable'
 user: <DB_USER>
 password: <DB_PASSWORD>

Similar settings are applied when configuring Xray with an RDS database:
postgresql:
 enabled: false
database:
    type: postgresql
    driver: org.postgresql.Driver
    url: "postgres://test.postgres.database.azure.com:5432/xraydb?sslmode=disable"
    username: "xray@test"
    password: xray
    actualUsername: xray@test