mirror of
https://github.com/embarklabs/embark.git
synced 2025-01-09 21:35:58 +00:00
fix(@embark/whisper): show message when geth port is already taken
This commit is contained in:
parent
dba5f771f2
commit
23f9a8c49c
@ -222,7 +222,7 @@ Blockchain.prototype.run = function () {
|
|||||||
// TOCHECK I don't understand why stderr and stdout are reverted.
|
// TOCHECK I don't understand why stderr and stdout are reverted.
|
||||||
// This happens with Geth and Parity, so it does not seems a client problem
|
// This happens with Geth and Parity, so it does not seems a client problem
|
||||||
self.child.stdout.on('data', (data) => {
|
self.child.stdout.on('data', (data) => {
|
||||||
self.logger.info(`${self.client.name} error: ${data}`);
|
self.logger.error(`${self.client.name} error: ${data}`);
|
||||||
});
|
});
|
||||||
|
|
||||||
self.child.stderr.on('data', async (data) => {
|
self.child.stderr.on('data', async (data) => {
|
||||||
|
@ -169,7 +169,7 @@ class WhisperGethClient {
|
|||||||
if (config.wsRPC) {
|
if (config.wsRPC) {
|
||||||
cmd.push("--ws");
|
cmd.push("--ws");
|
||||||
|
|
||||||
cmd.push(`--wsport=${communicationConfig.connection.port || config.wsPost++}`);
|
cmd.push(`--wsport=${communicationConfig.connection.port || config.wsPort++}`);
|
||||||
cmd.push(`--wsaddr=${communicationConfig.connection.host || config.wsHost++}`);
|
cmd.push(`--wsaddr=${communicationConfig.connection.host || config.wsHost++}`);
|
||||||
|
|
||||||
if (config.wsOrigins) {
|
if (config.wsOrigins) {
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
import { __ } from 'embark-i18n';
|
import { __ } from 'embark-i18n';
|
||||||
import {dappPath, canonicalHost, defaultHost} from 'embark-utils';
|
import {canonicalHost, defaultHost} from 'embark-utils';
|
||||||
const constants = require('embark-core/constants');
|
|
||||||
const API = require('./api.js');
|
const API = require('./api.js');
|
||||||
|
|
||||||
class Whisper {
|
class Whisper {
|
||||||
@ -11,8 +10,6 @@ class Whisper {
|
|||||||
this.communicationConfig = embark.config.communicationConfig;
|
this.communicationConfig = embark.config.communicationConfig;
|
||||||
this.embarkConfig = embark.config.embarkConfig;
|
this.embarkConfig = embark.config.embarkConfig;
|
||||||
this.embark = embark;
|
this.embark = embark;
|
||||||
this.webSocketsChannels = {};
|
|
||||||
this.modulesPath = dappPath(embark.config.embarkConfig.generationDir, constants.dappArtifacts.symlinkDir);
|
|
||||||
|
|
||||||
this.api = new API(embark);
|
this.api = new API(embark);
|
||||||
this.whisperNodes = {};
|
this.whisperNodes = {};
|
||||||
@ -42,7 +39,7 @@ class Whisper {
|
|||||||
let connection = this.communicationConfig.connection || {};
|
let connection = this.communicationConfig.connection || {};
|
||||||
const config = {
|
const config = {
|
||||||
server: canonicalHost(connection.host || defaultHost),
|
server: canonicalHost(connection.host || defaultHost),
|
||||||
port: connection.port || '8546',
|
port: connection.port || '8557',
|
||||||
type: connection.type || 'ws'
|
type: connection.type || 'ws'
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user