2020-11-27 01:05:10 -05:00
|
|
|
require('dotenv').config();
|
|
|
|
const express = require('express');
|
|
|
|
var https = require('https');
|
|
|
|
var bodyParser = require('body-parser');
|
|
|
|
const server = express();
|
|
|
|
var fs = require('fs');
|
|
|
|
var readline = require('readline');
|
|
|
|
|
2020-11-27 01:02:31 -05:00
|
|
|
const pg = require('pg')
|
|
|
|
|
|
|
|
const client = new pg.Client({
|
2020-11-27 01:01:42 -05:00
|
|
|
user: 'api',
|
2020-11-27 00:40:08 -05:00
|
|
|
host: '192.168.1.110',
|
|
|
|
database: 'ubm',
|
2020-11-27 01:01:42 -05:00
|
|
|
password: 'qqqx53!028',
|
|
|
|
port: 5433,
|
2020-11-27 00:40:08 -05:00
|
|
|
})
|
|
|
|
client.connect()
|
2020-11-27 01:05:10 -05:00
|
|
|
client.query('SELECT 1', (err, res) => {
|
2020-11-27 00:40:08 -05:00
|
|
|
console.log(err, res)
|
|
|
|
client.end()
|
|
|
|
})
|