forked from NebulaServices/Dispenser
-
Notifications
You must be signed in to change notification settings - Fork 8
Postgres Installation
Bubbo edited this page Sep 26, 2024
·
1 revision
-
Update package list:
sudo apt update
-
Install PostgreSQL:
sudo apt install -y postgresql postgresql-contrib
-
Start PostgreSQL service:
sudo systemctl start postgresql
-
Enable PostgreSQL to start on boot:
sudo systemctl enable postgresql -
Access PostgreSQL as
postgresuser and create a database:sudo -u postgres psql
Once inside the PostgreSQL prompt, you can create a database:
CREATE DATABASE dbname;
-
Add the postgres URL to the DB
postgresql://username:password@hostname:port/databasename