|
| 1 | +const LICENSE_PRICE = "1000000000000000000"; // 10 * Math.pow(1, 18) |
| 2 | +const ARB_LICENSE_PRICE = "1000000000000000000"; // 10 * Math.pow(10, 18) |
| 3 | +const FEE_MILLI_PERCENT = "1000"; // 1 percent |
| 4 | +const BURN_ADDRESS = "0x0000000000000000000000000000000000000002"; |
| 5 | +const MAINNET_OWNER = "0x35f7C96C392cD70ca5DBaeDB2005a946A82e8a95"; |
| 6 | +const RINKEBY_OWNER = "0xa019702a5743aFdd607c61321A90C43a8C1c69d9"; |
| 7 | +const FALLBACK_ARBITRATOR_MAINNET = "0x35f7C96C392cD70ca5DBaeDB2005a946A82e8a95"; |
| 8 | +const FALLBACK_ARBITRATOR_RINKEBY = "0xa019702a5743aFdd607c61321A90C43a8C1c69d9"; |
| 9 | +const GAS_PRICE = "5000000000"; //5 gwei |
| 10 | + |
| 11 | + |
| 12 | +const dataMigration = require('./data.js'); |
| 13 | + |
| 14 | +module.exports = { |
| 15 | + default: { |
| 16 | + dappConnection: [ |
| 17 | + "$EMBARK", |
| 18 | + "$WEB3", |
| 19 | + "ws://localhost:8546", |
| 20 | + "http://localhost:8545" |
| 21 | + ], |
| 22 | + |
| 23 | + dappAutoEnable: false, |
| 24 | + |
| 25 | + gas: "auto", |
| 26 | + |
| 27 | + strategy: 'explicit', |
| 28 | + |
| 29 | + deploy: { |
| 30 | + Proxy: { |
| 31 | + deploy: false |
| 32 | + }, |
| 33 | + License: { |
| 34 | + deploy: false |
| 35 | + }, |
| 36 | + SellerLicense: { |
| 37 | + instanceOf: "License", |
| 38 | + args: [ |
| 39 | + "$SNT", |
| 40 | + LICENSE_PRICE, |
| 41 | + "$KyberFeeBurner" // TODO: replace with "$StakingPool" |
| 42 | + ] |
| 43 | + }, |
| 44 | + SellerLicenseInstance: { |
| 45 | + instanceOf: "Proxy", |
| 46 | + proxyFor: 'SellerLicense', |
| 47 | + args: ["0x", "$SellerLicense"] |
| 48 | + }, |
| 49 | + ArbitrationLicense: { |
| 50 | + args: [ |
| 51 | + "$SNT", |
| 52 | + ARB_LICENSE_PRICE, |
| 53 | + "$KyberFeeBurner" // TODO: replace with "$StakingPool" |
| 54 | + ] |
| 55 | + }, |
| 56 | + ArbitrationLicenseInstance: { |
| 57 | + instanceOf: "Proxy", |
| 58 | + proxyFor: "ArbitrationLicense", |
| 59 | + args: ["0x", "$ArbitrationLicense"] |
| 60 | + }, |
| 61 | + UserStore: { |
| 62 | + args: ["$SellerLicense", "$ArbitrationLicense"] |
| 63 | + }, |
| 64 | + Medianizer: { |
| 65 | + |
| 66 | + }, |
| 67 | + OfferStore: { |
| 68 | + args: ["$UserStore", "$SellerLicense", "$ArbitrationLicense", BURN_ADDRESS, "$Medianizer"] |
| 69 | + }, |
| 70 | + UserStoreInstance: { |
| 71 | + instanceOf: "Proxy", |
| 72 | + proxyFor: "UserStore", |
| 73 | + args: ["0x", "$UserStore"] |
| 74 | + }, |
| 75 | + OfferStoreInstance: { |
| 76 | + instanceOf: "Proxy", |
| 77 | + proxyFor: "OfferStore", |
| 78 | + args: ["0x", "$OfferStore"] |
| 79 | + }, |
| 80 | + Escrow: { |
| 81 | + args: ["$accounts[0]", FALLBACK_ARBITRATOR_MAINNET, "$ArbitrationLicense", "$OfferStore", "$UserStore", "$KyberFeeBurner", FEE_MILLI_PERCENT] |
| 82 | + }, |
| 83 | + EscrowInstance: { |
| 84 | + instanceOf: "Proxy", |
| 85 | + proxyFor: "Escrow", |
| 86 | + args: ["0x", "$Escrow"] |
| 87 | + }, |
| 88 | + "MiniMeToken": {"deploy": false}, |
| 89 | + "MiniMeTokenFactory": {}, |
| 90 | + "Fees": { |
| 91 | + "deploy": false |
| 92 | + }, |
| 93 | + "SNT": { |
| 94 | + "instanceOf": "MiniMeToken", |
| 95 | + "args": [ |
| 96 | + "$MiniMeTokenFactory", |
| 97 | + "0x0000000000000000000000000000000000000000", |
| 98 | + 0, |
| 99 | + "TestMiniMeToken", |
| 100 | + 18, |
| 101 | + "STT", |
| 102 | + true |
| 103 | + ] |
| 104 | + }, |
| 105 | + |
| 106 | + /* |
| 107 | + "StakingPool": { |
| 108 | + file: 'staking-pool/contracts/StakingPool.sol', |
| 109 | + args: [ |
| 110 | + "$SNT" |
| 111 | + ] |
| 112 | + }, |
| 113 | + */ |
| 114 | + |
| 115 | + KyberNetworkProxy: {}, |
| 116 | + KyberFeeBurner: { // TODO: replace BURN_ADDRESS with "$StakingPool" |
| 117 | + args: ["$SNT", BURN_ADDRESS, "$KyberNetworkProxy", "0x0000000000000000000000000000000000000000", "300"] |
| 118 | + } |
| 119 | + } |
| 120 | + }, |
| 121 | + |
| 122 | + development: { |
| 123 | + deploy: { |
| 124 | + StandardToken: {}, |
| 125 | + DAI: {instanceOf: "StandardToken", onDeploy: ["DAI.methods.mint('$accounts[0]', '20000000000000000000').send()"]}, |
| 126 | + MKR: {instanceOf: "StandardToken", onDeploy: ["MKR.methods.mint('$accounts[0]', '20000000000000000000').send()"]} |
| 127 | + }, |
| 128 | + afterDeploy: dataMigration.bind(null, GAS_PRICE, LICENSE_PRICE, ARB_LICENSE_PRICE, FEE_MILLI_PERCENT, BURN_ADDRESS, null, null) |
| 129 | + }, |
| 130 | + |
| 131 | + |
| 132 | + testnet: { |
| 133 | + gasPrice: GAS_PRICE, |
| 134 | + tracking: 'shared.rinkeby.json', |
| 135 | + afterDeploy: dataMigration.bind(null, GAS_PRICE, LICENSE_PRICE, ARB_LICENSE_PRICE, FEE_MILLI_PERCENT, BURN_ADDRESS, RINKEBY_OWNER, RINKEBY_OWNER), |
| 136 | + dappConnection: [ |
| 137 | + "$WEB3", |
| 138 | + "https://rinkeby.infura.io/v3/c26e9ab0df094a4f99bd1ea030eb7d50" |
| 139 | + ], |
| 140 | + deploy: { |
| 141 | + StandardToken: {deploy: false}, |
| 142 | + DAI: {deploy: false}, |
| 143 | + MKR: {deploy: false}, |
| 144 | + KyberNetworkProxy: { |
| 145 | + // https://developer.kyber.network/docs/Environments-Rinkeby/ |
| 146 | + address: "0xF77eC7Ed5f5B9a5aee4cfa6FFCaC6A4C315BaC76" |
| 147 | + } |
| 148 | + } |
| 149 | + }, |
| 150 | + |
| 151 | + ropsten: { |
| 152 | + gasPrice: "10000000000", |
| 153 | + tracking: 'shared.ropsten.json', |
| 154 | + deploy: { |
| 155 | + SNT: { |
| 156 | + address: "0xc55cf4b03948d7ebc8b9e8bad92643703811d162" |
| 157 | + }, |
| 158 | + "MiniMeTokenFactory": { |
| 159 | + deploy: false |
| 160 | + }, |
| 161 | + KyberNetworkProxy: { |
| 162 | + // https://developer.kyber.network/docs/Environments-Ropsten/ |
| 163 | + address: "0x818E6FECD516Ecc3849DAf6845e3EC868087B755" |
| 164 | + } |
| 165 | + }, |
| 166 | + afterDeploy: dataMigration.bind(null, GAS_PRICE, LICENSE_PRICE, ARB_LICENSE_PRICE, FEE_MILLI_PERCENT, BURN_ADDRESS, MAINNET_OWNER, FALLBACK_ARBITRATOR_RINKEBY), |
| 167 | + dappConnection: ["$WEB3"] |
| 168 | + }, |
| 169 | + |
| 170 | + // merges with the settings in default |
| 171 | + // used with "embark run livenet" |
| 172 | + livenet: { |
| 173 | + gasPrice: GAS_PRICE, |
| 174 | + tracking: 'shared.mainnet.json', |
| 175 | + afterDeploy: dataMigration.bind(null, GAS_PRICE, LICENSE_PRICE, ARB_LICENSE_PRICE, FEE_MILLI_PERCENT, BURN_ADDRESS, MAINNET_OWNER, FALLBACK_ARBITRATOR_MAINNET), |
| 176 | + dappConnection: [ |
| 177 | + "$WEB3", |
| 178 | + "https://mainnet.infura.io/v3/c26e9ab0df094a4f99bd1ea030eb7d50" |
| 179 | + ], |
| 180 | + deploy: { |
| 181 | + StandardToken: {deploy: false}, |
| 182 | + DAI: {deploy: false}, |
| 183 | + MKR: {deploy: false}, |
| 184 | + SNT: { |
| 185 | + address: "0x744d70fdbe2ba4cf95131626614a1763df805b9e" |
| 186 | + }, |
| 187 | + "MiniMeTokenFactory": {deploy: false}, |
| 188 | + KyberNetworkProxy: { |
| 189 | + // https://developer.kyber.network/docs/Environments-Mainnet/ |
| 190 | + address: "0x818E6FECD516Ecc3849DAf6845e3EC868087B755" |
| 191 | + }, |
| 192 | + SellerLicense: { |
| 193 | + address: "0xD0fBD1a8D663B3D31312e0cb24910be82387266A" |
| 194 | + }, |
| 195 | + SellerLicenseInstance: { |
| 196 | + instanceOf: "Proxy", |
| 197 | + proxyFor: 'SellerLicense', |
| 198 | + address: "0x18C8e4570DE4D1FA07E2ad8BE4bc0Fe8B2C2dc4d" |
| 199 | + }, |
| 200 | + ArbitrationLicense: { |
| 201 | + address: "0x7e571b13aeb1a6abcfc470b7d033a6838e53f440" |
| 202 | + }, |
| 203 | + ArbitrationLicenseInstance: { |
| 204 | + instanceOf: "Proxy", |
| 205 | + proxyFor: 'ArbitrationLicense', |
| 206 | + address: "0x3e7fc31b9bd5fafde828acc1fd7b7b3dd7c1d927" |
| 207 | + }, |
| 208 | + UserStore: { |
| 209 | + address: "0x0ab611f28165a5b694959c1454c0a9027eae536d" |
| 210 | + }, |
| 211 | + Medianizer: { |
| 212 | + address: "0x729D19f657BD0614b4985Cf1D82531c67569197B" |
| 213 | + }, |
| 214 | + OfferStore: { |
| 215 | + address: "0x5EaE5D9Fc2F38d18D9F3Bfa584700801850670D0" |
| 216 | + }, |
| 217 | + UserStoreInstance: { |
| 218 | + instanceOf: "Proxy", |
| 219 | + proxyFor: "UserStore", |
| 220 | + address: "0x61fbacebcef64e726ff5b848da5dff0c44c199f5" |
| 221 | + }, |
| 222 | + OfferStoreInstance: { |
| 223 | + instanceOf: "Proxy", |
| 224 | + proxyFor: "OfferStore", |
| 225 | + address: "0xf0dfd170aedf576717b7de14dac257c832a364e2" |
| 226 | + }, |
| 227 | + Escrow: { |
| 228 | + address: "0x727bF4BAed69265bBaFD39f0ab6e508F6fA118a7" |
| 229 | + }, |
| 230 | + EscrowInstance: { |
| 231 | + instanceOf: "Proxy", |
| 232 | + proxyFor: 'Escrow', |
| 233 | + address: "0xD5baC31a10b8938dd47326f01802fa23f1032AeE" |
| 234 | + }, |
| 235 | + KyberFeeBurner: { |
| 236 | + address: "0x7702CaaE3D8feE750c4464d80FCb14Ce05e00743" |
| 237 | + } |
| 238 | + } |
| 239 | + } |
| 240 | +}; |
0 commit comments