Preparing testnet information

This commit is contained in:
Richard Ramos 2018-11-30 19:07:23 -04:00
parent a2a9141ead
commit 2ee19d44d1
9 changed files with 79 additions and 14 deletions

View File

@ -15,5 +15,5 @@ Gas relayer mplementation for economic abstraction. This project consists of two
## Deployment Details
| Contract | Ropsten Address | Mainnet Address |
| ---------------------------|------------------------------------------- | ------------------------------------------ |
| status/SNTController | 0xA77A1014F55157c3119FB3f53E653E42f8fa634c | - |
| identity/IdentityFactory | 0x7F106A1Bc637AC4AAed3DC72582749c4562D4323 | - |
| status/SNTController | 0x1f42B87b375b8ac6C77A8CAd8E78319c18695E75 | - |
| identity/IdentityFactory | 0xCf3473C2A50F7A94D3D7Dcc2BeBbeE989dAA014E | - |

View File

@ -11,7 +11,7 @@ module.exports = {
"port": 8545
},
"blockchain": {
"account": "0xb8d851486d1c953e31a44374aca11151d49b8bb3"
privateKey: "0x......" //
},
"whisper": {
"symKey": "0xd0d905c1c62b810b787141430417caf2b3f54cffadb395b7bb39fdeb8f17266b",
@ -28,8 +28,8 @@ module.exports = {
"minAcceptedRate": 1,
"refreshPricePeriod": 60000
},
"0x91a3473a3e1e3D61C29fa2fAcDf17fa0Db922a08": {
"name": "Status Gas Relayer Test Token",
"0x139724523662E54447B70d043b711b2A00c5EF49": {
"name": "Status Test Token",
"symbol": "SNT",
"minAcceptedRate": 150000000000000,
"refreshPricePeriod": 60000,
@ -41,7 +41,7 @@ module.exports = {
"IdentityGasRelay": {
"abiFile": "../abi/IdentityGasRelay.json",
"isIdentity": true,
"factoryAddress": "0xC83a746c3B73457FF51eCE216bfBFb524aa4fDD0",
"factoryAddress": "0xCf3473C2A50F7A94D3D7Dcc2BeBbeE989dAA014E",
"kernelVerification": "isKernel(bytes32)",
"allowedFunctions": [
{
@ -58,7 +58,7 @@ module.exports = {
"SNTController": {
"abiFile": "../abi/SNTController.json",
"isIdentity": false,
"address": "0x39bFD424c2A83ca56FD557b373C01A27475bB314",
"address": "0x1f42B87b375b8ac6C77A8CAd8E78319c18695E75",
"allowedFunctions": [
{
"function":"transferSNT(address,uint256,uint256,uint256,bytes)"

View File

@ -1,2 +1,4 @@
#!/bin/bash
geth --testnet --syncmode=light --port=30303 --rpc --rpcport=8545 --rpcaddr=localhost --rpccorsdomain=http://localhost:8000 --ws --wsport=8546 --wsaddr=localhost --wsorigins="gas-relayer" --shh --shh.pow=0.002 --rpcapi=eth,web3,net,shh --wsapi=eth,web3,net,shh
#!/bin/bash
geth --testnet --syncmode=light --port=30303 --ws --wsport=8546 --wsaddr=localhost --wsorigins=http://localhost:8000,embark,gas-relayer --maxpeers=25 --shh --shh.pow=0.002 --wsapi=eth,web3,net,shh

View File

@ -29,7 +29,7 @@ const events = new EventEmitter();
// Web3 Connection
const connectionURL = `${config.node.local.protocol}://${config.node.local.host}:${config.node.local.port}`;
const wsProvider = new Web3.providers.WebsocketProvider(connectionURL, {headers: {Origin: "embark"}});
const wsProvider = new Web3.providers.WebsocketProvider(connectionURL, {headers: {Origin: "gas-relayer"}});
const web3 = new Web3(wsProvider);
let account;

View File

@ -13,7 +13,7 @@
<p>The following demos are available:</p>
<ul>
<li><a href="./sntcontroller.html">sntcontroller.html</a></li>
<li><a href="./identity.html">identity.html (Testnet requires nonce issue to be fixed)</a></li>
<li><a href="./identity.html">identity.html</a></li>
</ul>
</body>

View File

@ -74,9 +74,9 @@ class StatusGasRelayer {
web3.shh.subscribe('messages', {
"privateKeyID": options.privateKeyID,
"ttl": options.ttl || 1000,
"ttl": options.ttl || 10,
"minPow": options.minPow || 0.002,
"powTime": options.powTime || 1000
"powTime": options.powTime || 1
}, (error, message) => {
if(error){
cb(error);

View File

@ -7,7 +7,7 @@ module.exports = {
rpcCorsDomain: "auto", // Comma separated list of domains from which to accept cross origin requests (browser enforced)
// When set to "auto", Embark will automatically set the cors to the address of the webserver
wsRPC: true, // Enable the WS-RPC server
wsOrigins: "auto", // Origins from which to accept websockets requests
wsOrigins: "http://localhost:8000,gas-relayer", // Origins from which to accept websockets requests
// When set to "auto", Embark will automatically set the cors to the address of the webserver
wsHost: "localhost", // WS-RPC server listening interface (default: "localhost")
wsPort: 8546 // WS-RPC server listening port (default: 8546)

View File

@ -1,5 +1,6 @@
module.exports = {
// default applies to all environments
default: {
// Blockchain node to deploy the contracts
deployment: {
@ -98,6 +99,68 @@ module.exports = {
// merges with the settings in default
// used with "embark run testnet"
testnet: {
deployment: {
accounts: [
{
privateKey: '5AC0FF313884BC134DC5B8D92C40360BFB9FC16F8552B60587D27C942564201E',
}
],
host: "ropsten.infura.io/v3/e62b6ada19b042ee9c6d68746b965ccf",
port: false,
protocol: 'https', // <=== must be specified for infura, can also be http, or ws
type: "rpc"
},
contracts: {
// Reuse contracts on testnet
"MiniMeTokenFactory": {
"address": "0x6bfa86a71a7dbc68566d5c741f416e3009804279"
},
"STT": {
"instanceOf": "TestMiniMeToken",
"address": "0x139724523662E54447B70d043b711b2A00c5EF49"
},
"SNTController": {
"address": "0x1f42B87b375b8ac6C77A8CAd8E78319c18695E75"
},
"IdentityGasRelay": {
"deploy": false
},
"IdentityFactory": {
"address": "0xCf3473C2A50F7A94D3D7Dcc2BeBbeE989dAA014E"
},
"TestContract": {
"address": "0x19fbEE3C3eB0070Df1ab9ba4cB8ab24F0efEBdF8"
}
// Deploy new contracts to testnet
/*
"MiniMeTokenFactory": {
"address": "0x6bfa86a71a7dbc68566d5c741f416e3009804279"
},
"STT": {
"instanceOf": "TestMiniMeToken",
"args":["$MiniMeTokenFactory", "0x0", "0x0", "Status Gas Relayer Test Token", 18, "SGasT", true],
"gasLimit": 4000000
},
"SNTController": {
"args": ["$accounts[0]", "$STT"],
},
"IdentityGasRelay": {
"deploy": true,
"args": [[], [], [], 1, 1, "0x0000000000000000000000000000000000000000"]
},
"IdentityFactory": {
"args":[],
"gasLimit": 5000000
},
"TestContract": {
"args": ["$STT"]
}*/
},
"afterDeploy": [
"STT.methods.changeController(SNTController.options.address).send()",
"SNTController.methods.enablePublicExecution(TestContract.options.address, true).send()"
]
},
// merges with the settings in default

View File

@ -1,3 +1,3 @@
#!/bin/bash
geth --testnet --syncmode=light --password=config/testnet/password --port=30303 --rpc --rpcport=8545 --rpcaddr=localhost --rpccorsdomain=http://localhost:8000 --ws --wsport=8546 --wsaddr=localhost --wsorigins=http://localhost:8000,http://localhost:8080 --maxpeers=25 --shh --shh.pow=0.002 --rpcapi=eth,web3,net,debug,shh --wsapi=eth,web3,net,shh,debug --unlock=7c13ad39c6c2b2ee9ada21482751be478df7fac7
geth --testnet --syncmode=light --port=30303 --ws --wsport=8546 --wsaddr=localhost --wsorigins=http://localhost:8000,embark,gas-relayer --maxpeers=25 --shh --shh.pow=0.002 --wsapi=eth,web3,net,shh