Add psql version to info page
This commit is contained in:
parent
33d79420eb
commit
2c1932faa7
|
@ -20,6 +20,7 @@ import { Users, Notes, Emojis, UserProfiles, Pages } from '../../models';
|
||||||
import parseAcct from '../../misc/acct/parse';
|
import parseAcct from '../../misc/acct/parse';
|
||||||
import getNoteSummary from '../../misc/get-note-summary';
|
import getNoteSummary from '../../misc/get-note-summary';
|
||||||
import { ensure } from '../../prelude/ensure';
|
import { ensure } from '../../prelude/ensure';
|
||||||
|
import { getConnection } from 'typeorm';
|
||||||
|
|
||||||
const client = `${__dirname}/../../client/`;
|
const client = `${__dirname}/../../client/`;
|
||||||
|
|
||||||
|
@ -250,6 +251,7 @@ router.get('/info', async ctx => {
|
||||||
machine: os.hostname(),
|
machine: os.hostname(),
|
||||||
os: os.platform(),
|
os: os.platform(),
|
||||||
node: process.version,
|
node: process.version,
|
||||||
|
psql: await getConnection().query('SHOW server_version').then(x => x[0].server_version),
|
||||||
cpu: {
|
cpu: {
|
||||||
model: os.cpus()[0].model,
|
model: os.cpus()[0].model,
|
||||||
cores: os.cpus().length
|
cores: os.cpus().length
|
||||||
|
|
|
@ -85,6 +85,9 @@ html
|
||||||
tr
|
tr
|
||||||
th Node version
|
th Node version
|
||||||
td= node
|
td= node
|
||||||
|
tr
|
||||||
|
th PSQL version
|
||||||
|
td= psql
|
||||||
tr
|
tr
|
||||||
th Machine
|
th Machine
|
||||||
td= machine
|
td= machine
|
||||||
|
|
Loading…
Reference in New Issue