Skip to content

Commit

Permalink
version compatible with geth 1.0.0, loading genesis block with diffic…
Browse files Browse the repository at this point in the history
…ulty 0
  • Loading branch information
debris committed Jul 31, 2015
1 parent 7cf70d5 commit de51ad6
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 5 deletions.
4 changes: 2 additions & 2 deletions config.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
"jsonrpc_port": "8101",
"exchange_interface": "http",
"exchange_port": 8545,
"owner": "0x29f1467c4f755e074fccfb5e9cd8bf2c02eaaf95",
"namereg": "0x9499660747fcfc52e0b218fcd83fa5f7de869a8a"
"owner": "0xe03445545976cdea775864581a4895159fc7679c",
"namereg": "0x7f6013517413d5ce1e42aa91865f2460474ba96c"
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "smart-exchange",
"version": "1.0.0",
"version": "1.0.1",
"description": "",
"main": "./lib/interface.js",
"bin": "./app.js",
Expand Down
11 changes: 11 additions & 0 deletions testnet/genesis_block.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"nonce": "0x0000000000000042",
"difficulty": "0x1",
"alloc": {},
"mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"coinbase": "0x0000000000000000000000000000000000000000",
"timestamp": "0x00",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "0x11bbe8db4e347b4e8c937c1c8370e4b5ed33adb3db69cbdb7a38e1e50b1b82fa",
"gasLimit": "0x2fefd8"
}
7 changes: 5 additions & 2 deletions testnet/testnet_start.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ var basicCommand = function (config) {
//cmd = addArg(cmd, '--mine');
cmd = addArg(cmd, '--maxpeers=0');
cmd = addArg(cmd, '--verbosity=0');
cmd = addArg(cmd, '--genesis ' + './testnet/genesis_block.json');
cmd = addArg(cmd, '--password ' + './testnet/password/password');

var networkId = Math.floor((Math.random() * 100000) + 1000);
Expand Down Expand Up @@ -76,11 +77,13 @@ var run = function (config, address) {
});

geth.on('error', function (data) {
log.warn(data.toString());
log.error(data.toString());
process.exit(1);
});

geth.on('close', function (code) {
log.warn('child process exited with code ' + code);
log.error('child process exited with code ' + code);
process.exit(1);
});
};

Expand Down

0 comments on commit de51ad6

Please sign in to comment.