mirror of
https://github.com/Redume/Kekkai.git
synced 2025-02-23 20:51:25 +03:00
обновление конфига
This commit is contained in:
parent
30163b4a5b
commit
84a0c0502f
2 changed files with 18 additions and 10 deletions
|
@ -1,5 +1,13 @@
|
||||||
db_user: "DATABASE_USERNAME"
|
db:
|
||||||
db_password: "DATABASE_PASSWORD"
|
user: "DATABASE_USERNAME"
|
||||||
db_host: "DATABASE_HOST"
|
password: "DATABASE_PASSWORD"
|
||||||
db_name: "DATABASE_NAME"
|
host: "DATABASE_HOST"
|
||||||
db_port: 5432
|
name: "DATABASE_NAME"
|
||||||
|
port: 5432
|
||||||
|
currency:
|
||||||
|
- USD
|
||||||
|
- RUB
|
||||||
|
- EUR
|
||||||
|
- UAH
|
||||||
|
- TRY
|
||||||
|
- KZT
|
|
@ -4,11 +4,11 @@ const fs = require("fs");
|
||||||
const config = yaml.parse(fs.readFileSync("./config.yaml", "utf-8"));
|
const config = yaml.parse(fs.readFileSync("./config.yaml", "utf-8"));
|
||||||
|
|
||||||
const pool = new pg.Pool({
|
const pool = new pg.Pool({
|
||||||
user: config['db_user'],
|
user: config['db']['user'],
|
||||||
password: config['db_password'],
|
password: config['db']['password'],
|
||||||
host: config['db_host'],
|
host: config['db']['host'],
|
||||||
port: config['db_port'],
|
port: config['db']['port'],
|
||||||
database: config['db_name']
|
database: config['db']['name']
|
||||||
});
|
});
|
||||||
|
|
||||||
module.exports = pool;
|
module.exports = pool;
|
||||||
|
|
Loading…
Add table
Reference in a new issue