mirror of
https://github.com/status-im/embark-area-51.git
synced 2025-01-24 06:08:48 +00:00
conflict in en.json
This commit is contained in:
parent
21a0042d00
commit
12525fb9bf
@ -125,7 +125,7 @@ Blockchain.prototype.run = function() {
|
|||||||
});
|
});
|
||||||
child.on('exit', (code) => {
|
child.on('exit', (code) => {
|
||||||
if (code) {
|
if (code) {
|
||||||
console.error('Geth exited with error code ' + 1);
|
console.error('Geth exited with error code ' + code);
|
||||||
console.error(lastMessage);
|
console.error(lastMessage);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -135,6 +135,8 @@
|
|||||||
"deploying to swarm!": "deploying to swarm!",
|
"deploying to swarm!": "deploying to swarm!",
|
||||||
"adding %s to swarm": "adding %s to swarm",
|
"adding %s to swarm": "adding %s to swarm",
|
||||||
"error uploading to swarm": "error uploading to swarm",
|
"error uploading to swarm": "error uploading to swarm",
|
||||||
|
"Starting ipfs process": "Starting ipfs process",
|
||||||
|
"Storage process for ipfs ended before the end of this process. Code: 0": "Storage process for ipfs ended before the end of this process. Code: 0",
|
||||||
"WARNING! DApp path length is too long: ": "WARNING! DApp path length is too long: ",
|
"WARNING! DApp path length is too long: ": "WARNING! DApp path length is too long: ",
|
||||||
"This is known to cause issues with starting geth, please consider reducing your DApp path's length to 66 characters or less.": "This is known to cause issues with starting geth, please consider reducing your DApp path's length to 66 characters or less.",
|
"This is known to cause issues with starting geth, please consider reducing your DApp path's length to 66 characters or less.": "This is known to cause issues with starting geth, please consider reducing your DApp path's length to 66 characters or less.",
|
||||||
"Installing packages...": "Installing packages...",
|
"Installing packages...": "Installing packages...",
|
||||||
@ -143,4 +145,4 @@
|
|||||||
"For more info go to http://embark.status.im": "For more info go to http://embark.status.im",
|
"For more info go to http://embark.status.im": "For more info go to http://embark.status.im",
|
||||||
"%s is not installed on your machine": "%s is not installed on your machine",
|
"%s is not installed on your machine": "%s is not installed on your machine",
|
||||||
"You can install it by visiting: %s": "You can install it by visiting: %s"
|
"You can install it by visiting: %s": "You can install it by visiting: %s"
|
||||||
}
|
}
|
||||||
|
25
lib/index.js
25
lib/index.js
@ -335,8 +335,19 @@ class Embark {
|
|||||||
if (!checkFn || typeof checkFn.fn !== 'function') {
|
if (!checkFn || typeof checkFn.fn !== 'function') {
|
||||||
return callback();
|
return callback();
|
||||||
}
|
}
|
||||||
checkFn.fn(function (serviceCheckResult) {
|
|
||||||
if (!serviceCheckResult.status || serviceCheckResult.status === 'off') {
|
const erroObj = {message: __('Cannot upload: {{platform}} node is not running on {{protocol}}://{{host}}:{{port}}.', {platform: platform, protocol: engine.config.storageConfig.protocol, host: engine.config.storageConfig.host, port: engine.config.storageConfig.port})};
|
||||||
|
function checkEndpoint(cb) {
|
||||||
|
checkFn.fn(function (serviceCheckResult) {
|
||||||
|
if (!serviceCheckResult.status || serviceCheckResult.status === 'off') {
|
||||||
|
return cb(erroObj);
|
||||||
|
}
|
||||||
|
cb();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
checkEndpoint(function (err) {
|
||||||
|
if (err) {
|
||||||
const storageProcessesLauncher = new StorageProcessesLauncher({
|
const storageProcessesLauncher = new StorageProcessesLauncher({
|
||||||
logger: engine.logger,
|
logger: engine.logger,
|
||||||
events: engine.events,
|
events: engine.events,
|
||||||
@ -345,9 +356,15 @@ class Embark {
|
|||||||
return storageProcessesLauncher.launchProcess(platform.toLowerCase(), (err) => {
|
return storageProcessesLauncher.launchProcess(platform.toLowerCase(), (err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
engine.logger.error(err);
|
engine.logger.error(err);
|
||||||
return callback({message: __('Cannot upload: {{platform}} node is not running on {{protocol}}://{{host}}:{{port}}.', {platform: platform, protocol: engine.config.storageConfig.protocol, host: engine.config.storageConfig.host, port: engine.config.storageConfig.port})});
|
return callback(erroObj);
|
||||||
}
|
}
|
||||||
callback();
|
// Check endpoint again to see if really did start
|
||||||
|
checkEndpoint((err) => {
|
||||||
|
if (err) {
|
||||||
|
return callback(err);
|
||||||
|
}
|
||||||
|
callback();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
callback();
|
callback();
|
||||||
|
@ -2,7 +2,7 @@ const shelljs = require('shelljs');
|
|||||||
const ProcessWrapper = require('../../process/processWrapper');
|
const ProcessWrapper = require('../../process/processWrapper');
|
||||||
const constants = require('../../constants');
|
const constants = require('../../constants');
|
||||||
|
|
||||||
let ipfsProcess;
|
let ipfsProcess; // eslint-disable-line no-unused-vars
|
||||||
|
|
||||||
class IPFSProcess extends ProcessWrapper {
|
class IPFSProcess extends ProcessWrapper {
|
||||||
constructor(_options) {
|
constructor(_options) {
|
||||||
@ -12,19 +12,34 @@ class IPFSProcess extends ProcessWrapper {
|
|||||||
}
|
}
|
||||||
|
|
||||||
startIPFSDaemon() {
|
startIPFSDaemon() {
|
||||||
shelljs.exec('ipfs daemon', {silent: true}, (err, _stdout, _stderr) => {
|
const self = this;
|
||||||
|
const child = shelljs.exec('ipfs daemon', {silent: true}, (err, _stdout, _stderr) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
console.error(err);
|
console.error(err);
|
||||||
process.exit(1);
|
process.exit(1);
|
||||||
}
|
}
|
||||||
process.exit();
|
process.exit();
|
||||||
});
|
});
|
||||||
|
let lastMessage;
|
||||||
|
child.stdout.on('data', (data) => {
|
||||||
|
if (!self.readyCalled && data.indexOf('Daemon is ready') > -1) {
|
||||||
|
self.readyCalled = true;
|
||||||
|
self.send({result: constants.storage.initiated});
|
||||||
|
}
|
||||||
|
lastMessage = data;
|
||||||
|
console.log('IPFS: ' + data);
|
||||||
|
});
|
||||||
|
child.on('exit', (code) => {
|
||||||
|
if (code) {
|
||||||
|
console.error('IPFS exited with error code ' + code);
|
||||||
|
console.error(lastMessage);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
process.on('message', (msg) => {
|
process.on('message', (msg) => {
|
||||||
if (msg.action === constants.storage.init) {
|
if (msg.action === constants.storage.init) {
|
||||||
ipfsProcess = new IPFSProcess(msg.options);
|
ipfsProcess = new IPFSProcess(msg.options);
|
||||||
return ipfsProcess.send({result: constants.storage.initiated});
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -21,11 +21,9 @@ class SwarmProcess extends ProcessWrapper {
|
|||||||
{
|
{
|
||||||
if (err) {
|
if (err) {
|
||||||
console.error(err);
|
console.error(err);
|
||||||
//process.exit(1);
|
process.exit(1);
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
console.log('Complete?')
|
process.exit();
|
||||||
//process.exit();
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user