Create the Xray PostgreSQL Database

JFrog Installation & Setup Documentation

ft:sourceType
Paligo

Supported PostgreSQL Versions

Xray supports PostgreSQL version 15.x and below (9.5 and 9.6 were EOL in 2021).

Use the following commands to create an Xray user and database with appropriate permissions. Modify the relevant values to match your specific environment:Creating an Xray User and Database

CREATE USER xray WITH PASSWORD 'password';
CREATE DATABASE xraydb WITH OWNER=xray ENCODING='UTF8';
GRANT ALL PRIVILEGES ON DATABASE xraydb TO xray;

If you use an RDS Amazon Aurora instance of PostgreSQL, run the following command in addition, where superUser is the RDS superuser that you use to log in to RDS.

GRANT xray TO superUser;

You can also run xray /app/third-party/postgresql/createPostgresUsers .sh in the installation folder.

Once you create the database and users, proceed with configuring the database.