Database Connection¶
Before you start¶
Goal
- Connect the hub to an existing Postgresql Database.
Prerequisites
- Have the credentials for the running Postgresql database.
- Administration privileges for the host.
Configuring the Hub database connection¶
Altair SLC Hub requires a connection to an SQL database to store relational data.
The connection to the database is configured using the database
configuration
section. A list of the configuration settings and comments on their use is found in the file [etc directory]/config.d/database.yaml
in the hub installation.
To configure a database connection, take a copy of this file and
save it to a file in the same directory with a lexicographically greater name.
For example, save it as database_custom.yaml
.
Then modify the settings in that file appropriately.
To avoid conflicts we recommended a dedicated database in the database server. For security, create a dedicated user for Altair SLC Hub to access that database. Altair SLC Hub requires table creation permission in order to run the database schema migration step.
Verification¶
Verify database
- run the hubctl verify db
Before continuing, it is necessary to verify that the connection information for the database is correct.
This can be done using the hubctl
commands, as follows:
hubctl verify db