aboutsummaryrefslogtreecommitdiff
path: root/modules/version.js
blob: 22a36670f2c7c232bccbf1b95e0e8e6bbc70b243 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
const body = require("body/json");
const crypto = require('crypto');
const fs = require('fs');
const os = require("os");

module.exports = (req, res, entry, dbid) => {
    res.writeHead(200, {'Content-Type':'application/json'});
    res.write(JSON.stringify({
        error: 200,
        ...process.versions,
        pawerdb: variables.version,
        os: os.type() + " " + os.arch() + " " + os.release(),
        user: os.userInfo()
    }));
    res.end();
}