Browse Source

05/25/2021 03:25:05 PM MST

master
coldstar 3 years ago
parent
commit
af403d91b4
1 changed files with 5 additions and 2 deletions
  1. +5
    -2
      routes/baseActionsRouter.js

+ 5
- 2
routes/baseActionsRouter.js View File

@@ -310,12 +310,15 @@ router.get("/address/:address", function(req, res) {
res.locals.address = address; res.locals.address = address;


console.log("address is:" + address); console.log("address is:" + address);

console.log('/usr/local/bin/vivo-cli -conf=/etc/masternodes/vivo_n1.conf getaddressbalance \'{\"addresses\": [\"" + address + "\"]}\'');

res.locals.result = {}; res.locals.result = {};




const { exec } = require('child_process'); const { exec } = require('child_process');
//var yourscript = exec('/usr/local/bin/vivo-cli -conf=/etc/masternodes/vivo_n1.conf getaddressbalance \'{\"addresses\": [\"" + address + "\"]}\'',
var yourscript = exec('whoami',
var yourscript = exec('/usr/local/bin/vivo-cli -conf=/etc/masternodes/vivo_n1.conf getaddressbalance \'{\"addresses\": [\"" + address + "\"]}\'',
//var yourscript = exec('whoami',
(error, stdout, stderr) => { (error, stdout, stderr) => {
console.log(stdout); console.log(stdout);
console.log(stderr); console.log(stderr);


Loading…
Cancel
Save