Commit f7a1c0e0 authored by Sergei Zubov's avatar Sergei Zubov

Modify daemon start

parent 36213223
......@@ -113,7 +113,7 @@ function closeDeStreamApi() {
var http2 = require('http');
const options2 = {
hostname: 'localhost',
port: 37221,
port: 56864,
path: '/api/node/shutdown',
method: 'POST'
};
......@@ -129,22 +129,22 @@ function startDeStreamApi() {
const spawnDeStream = require('child_process').spawn;
//Start Breeze DeStream Daemon
let apiPath = path.resolve(__dirname, 'assets//daemon//Stratis.BreezeD');
let apiPath = path.resolve(__dirname, 'assets//daemon//DeStream.DeStreamD');
if (os.platform() === 'win32') {
apiPath = path.resolve(__dirname, '..\\..\\resources\\daemon\\Stratis.BreezeD.exe');
apiPath = path.resolve(__dirname, '..\\..\\resources\\daemon\\DeStream.DeStreamD.exe');
} else if(os.platform() === 'linux') {
apiPath = path.resolve(__dirname, '..//..//resources//daemon//Stratis.BreezeD');
apiPath = path.resolve(__dirname, '..//..//resources//daemon//DeStream.DeStreamD');
} else {
apiPath = path.resolve(__dirname, '..//..//resources//daemon//Stratis.BreezeD');
apiPath = path.resolve(__dirname, '..//..//resources//daemon//DeStream.DeStreamD');
}
if (!testnet) {
destreamProcess = spawnDeStream(apiPath, ['destream'], {
detached: true
detached: false
});
} else if (testnet) {
destreamProcess = spawnDeStream(apiPath, ['destream', '-testnet'], {
detached: true
detached: false
});
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment