add docs for mariadb setup

This commit is contained in:
lesion 2021-12-09 09:31:01 +01:00
parent 1207069647
commit 2b2d0be7ca
No known key found for this signature in database
GPG key ID: 352918250B012177

View file

@ -21,8 +21,8 @@ sudo npm install -g yarn
```
<small>[source](https://github.com/nodesource/distributions/blob/master/README.md)</small>
1. Setup with postgreSQL __(optional as you can choose sqlite)__
#### Choose you database (sqlite, postgresql, mariadb, mysql)
1. Setup using postgreSQL __(optional)__
```bash
sudo apt-get install postgresql
# Create the database
@ -32,6 +32,18 @@ postgres=# create user gancio with encrypted password 'gancio';
postgres=# grant all privileges on database gancio to gancio;
```
1. Setup using MariaDB (__optional__)
```bash
sudo apt-get install mariadb
sudo mysql
MariaDB [(none)]> create database gancio;
Query OK, 1 row affected (0.001 sec)
MariaDB [(none)]> create user gancio identified by 'gancio';
Query OK, 0 rows affected (0.011 sec)
MariaDB [(none)]> grant all privileges on gancio.* to gancio;
Query OK, 0 rows affected (0.009 sec)
```
1. Create a user to run gancio from
```bash
sudo adduser --group --system --shell /bin/false --home /opt/gancio gancio