diff --git a/bin/ucoind b/bin/ucoind index 50e2cfec8c59c17f3df6706f87e6938acc86b863..54ce04a5716894cd6cce18d59dc24a51d22cf9c9 100755 --- a/bin/ucoind +++ b/bin/ucoind @@ -50,6 +50,10 @@ program .option('--upnp', 'Use UPnP to open remote port') .option('--noupnp', 'Do not use UPnP to open remote port') + // Webmin options + .option('--webmhost <host>', 'Local network interface to connect to (IP)') + .option('--webmport <port>', 'Local network port to connect', parseInt) + .option('--salt <salt>', 'Key salt to generate this key\'s secret key') .option('--passwd <password>', 'Password to generate this key\'s secret key') .option('--participate <Y|N>', 'Participate to writing the blockchain') @@ -798,7 +802,7 @@ function webStart() { // Add log files for this instance logger.addHomeLogs(params.home); } - let webminapi = yield ucoin.statics.enableHttpAdmin({ home: dbHome, name: dbName, memory: program.memory }, commandLineConf(), false); + let webminapi = yield ucoin.statics.enableHttpAdmin({ home: dbHome, name: dbName, memory: program.memory }, commandLineConf(), false, program.webmhost, program.webmport); return webminapi.openConnections(); }); diff --git a/index.js b/index.js index 377edcb23d9c3c90f0e9481293f3e1911b4e3052..be396de58a1901bcce64115b0fad881c671af53c 100644 --- a/index.js +++ b/index.js @@ -14,9 +14,9 @@ module.exports = function (dbConf, overConf) { module.exports.statics = { - enableHttpAdmin: (dbConf, overConf, httpLogs) => webmin(dbConf, overConf, [{ - ip: 'localhost', - port: 9220 + enableHttpAdmin: (dbConf, overConf, httpLogs, wmHost, wmPort) => webmin(dbConf, overConf, [{ + ip: wmHost || 'localhost', + port: wmPort || 9220 }], httpLogs !== false), startNode: (server, conf) => co(function *() {