mirror of
https://github.com/embarklabs/embark.git
synced 2025-02-03 01:13:55 +00:00
only use personal in --dev mode
This commit is contained in:
parent
eda616dc73
commit
69f356b3f0
@ -20,6 +20,11 @@ var Blockchain = function(options) {
|
|||||||
console.log("===> " + __("warning: running default config on a non-development environment"));
|
console.log("===> " + __("warning: running default config on a non-development environment"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let defaultWsApi = ['eth', 'web3', 'net', 'shh', 'debug'];
|
||||||
|
if (this.isDev) {
|
||||||
|
defaultWsApi.push('personal');
|
||||||
|
}
|
||||||
|
|
||||||
this.config = {
|
this.config = {
|
||||||
geth_bin: this.blockchainConfig.geth_bin || 'geth',
|
geth_bin: this.blockchainConfig.geth_bin || 'geth',
|
||||||
networkType: this.blockchainConfig.networkType || 'custom',
|
networkType: this.blockchainConfig.networkType || 'custom',
|
||||||
@ -42,7 +47,7 @@ var Blockchain = function(options) {
|
|||||||
wsHost: this.blockchainConfig.wsHost || 'localhost',
|
wsHost: this.blockchainConfig.wsHost || 'localhost',
|
||||||
wsPort: this.blockchainConfig.wsPort || 8546,
|
wsPort: this.blockchainConfig.wsPort || 8546,
|
||||||
wsOrigins: this.blockchainConfig.wsOrigins || false,
|
wsOrigins: this.blockchainConfig.wsOrigins || false,
|
||||||
wsApi: (this.blockchainConfig.wsApi || ['eth', 'web3', 'net', 'shh', 'debug', 'personal']),
|
wsApi: (this.blockchainConfig.wsApi || defaultWsApi),
|
||||||
vmdebug: this.blockchainConfig.vmdebug || false,
|
vmdebug: this.blockchainConfig.vmdebug || false,
|
||||||
targetGasLimit: this.blockchainConfig.targetGasLimit || false,
|
targetGasLimit: this.blockchainConfig.targetGasLimit || false,
|
||||||
syncMode: this.blockchainConfig.syncMode,
|
syncMode: this.blockchainConfig.syncMode,
|
||||||
|
@ -123,7 +123,13 @@ class GethCommands {
|
|||||||
let self = this;
|
let self = this;
|
||||||
let config = this.config;
|
let config = this.config;
|
||||||
let rpc_api = (this.config.rpcApi || ['eth', 'web3', 'net', 'debug']);
|
let rpc_api = (this.config.rpcApi || ['eth', 'web3', 'net', 'debug']);
|
||||||
let ws_api = (this.config.wsApi || ['eth', 'web3', 'net', 'debug', 'personal']);
|
|
||||||
|
let defaultWsApi = ['eth', 'web3', 'net', 'shh', 'debug'];
|
||||||
|
if (this.isDev) {
|
||||||
|
defaultWsApi.push('personal');
|
||||||
|
}
|
||||||
|
|
||||||
|
let ws_api = (this.config.wsApi || defaultWsApi);
|
||||||
|
|
||||||
let args = [];
|
let args = [];
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user