PostgreSQL
Using PostgreSQL on your serverlet.
PostgreSQL is an advanced open-source relational database system that provides high reliability, robustness, and rich functionality. Itβs suited for demanding applications that need complex queries and transactional integrity.
For more details on PostgreSQL, see the official documentation.
First use
By default, PostgreSQL is disabled on the serverlet. You can enable it from administration, on the serverletβs Software tab (see Serverlet Control):
Or via a terminal command:
$ app enable postgresqlStarting PostgreSQL:
$ app start postgresqlCreating and managing databases
Databases can be created and managed from the UI, or from SSH/CLI using the Futrou DB Manager tool.
Administration (UI)
You can add a new database with a user account in Administration, on the serverletβs Databases tab.
Futrou DB Manager (CLI)
Use the Futrou DB Manager tool to manage databases from the terminal:
Futrou DB Manager
Usage: db {name} list
Usage: db {name} add {database_name} {password}
Usage: db {name} update {database_name} {new_password}
Usage: db {name} del {database_name}
Supported databases: mariadb, mongodb, postgresql
Example: db postgresql listCommands:
db postgresql listβ lists all databasesdb postgresql add database_name passwordβ creates a new database with a user and passworddb postgresql update database_name new_passwordβ updates the password for a databasedb postgresql del database_nameβ deletes a database
Example:
$ db postgresql add moje_db tajne_hesloControl
Control PostgreSQL with:
$ psqlTo connect to a specific database:
$ psql -d database_nameConfiguration
All PostgreSQL configuration is stored in configuration files in the /srv/config/postgresql/ directory. The main configuration file is postgresql.conf.
Last updated
