This commit is contained in:
poma 2020-12-15 21:53:16 +03:00
parent b21330a3f6
commit c4d0c44ed1
No known key found for this signature in database
GPG Key ID: BA20CB01FE165657
5 changed files with 0 additions and 70 deletions

View File

@ -1,2 +0,0 @@
PRIVATE_KEY=
INFURA_TOKEN=97c8bf358b9942a9853fab1ba93dc5b3

View File

@ -9,35 +9,5 @@
```bash
$ yarn
$ cp .env.example .env
$ yarn test
```
## Deploying
Deploy to Kovan:
```bash
$ yarn deploy:kovan
```
## Mainnet deploy instructions
1. in torn-token repo `cp .env.example .env`
2. Specify deployment `PRIVATE_KEY` in the `.env`. It will be the owner during deployment.
3. Specify gas price in `truffle.js`
4. `yarn deploy:mainnet`
5. go to [mining](https://github.com/tornadocash/tornado-anonymity-mining) repo
6. `cp .env.example .env`
7. Specify private key and TORN address
8. yarn `yarn deploy:mainnet`
9. go to [governance](https://github.com/tornadocash/governance) repo
10. ...
11. ...
12. ...
13. in this repo modify the `config.js` file. Put all addresses that you got during deployment
14. set `ONLY_INITIALIZE` to `true` and `TORN_TO_INITIALIZE` to the token address
15. `yarn deploy:mainnet`

View File

@ -18,15 +18,6 @@
"prettier:check": "prettier --check . --config .prettierrc",
"prettier:fix": "prettier --write . --config .prettierrc",
"lint": "yarn eslint && yarn prettier:check",
"deploy:mainnet": "truffle migrate --network mainnet",
"deploy:kovan": "truffle migrate --network kovan",
"deploy:dev": "truffle migrate --skip-dry-run --network test",
"init:mainnet": "truffle migrate -f 2 --to 2 --network mainnet",
"init:kovan": "truffle migrate -f 2 --to 2 --network kovan",
"init:test": "truffle migrate -f 2 --to 2 --network test",
"voucher:mainnet": "truffle migrate -f 3 --network mainnet",
"voucher:kovan": "truffle migrate -f 3 --network kovan",
"voucher:dev": "truffle migrate -f 3 --skip-dry-run --network test",
"verify": "truffle run verify --network $NETWORK"
},
"devDependencies": {
@ -48,7 +39,6 @@
},
"dependencies": {
"@openzeppelin/contracts": "^3.1.0",
"dotenv": "^8.2.0",
"eth-sig-util": "^2.5.3",
"ethereumjs-util": "^7.0.3",
"web3": "^1.2.11"

View File

@ -1,8 +1,3 @@
require('dotenv').config()
const HDWalletProvider = require('truffle-hdwallet-provider')
const utils = require('web3-utils')
const { PRIVATE_KEY, INFURA_TOKEN } = process.env
module.exports = {
// Uncommenting the defaults below
// provides for an easier quick-start with Ganache.
@ -21,24 +16,6 @@ module.exports = {
// port: 8544,
// network_id: '*',
// },
mainnet: {
provider: () => new HDWalletProvider(PRIVATE_KEY, `https://mainnet.infura.io/v3/${INFURA_TOKEN}`),
network_id: 1,
gas: 6000000,
gasPrice: utils.toWei('100', 'gwei'),
// confirmations: 0,
// timeoutBlocks: 200,
skipDryRun: true,
},
kovan: {
provider: () => new HDWalletProvider(PRIVATE_KEY, `https://kovan.infura.io/v3/${INFURA_TOKEN}`),
network_id: 42,
gas: 6000000,
gasPrice: utils.toWei('1', 'gwei'),
// confirmations: 0,
// timeoutBlocks: 200,
skipDryRun: true,
},
coverage: {
host: 'localhost',
network_id: '*',

View File

@ -1452,11 +1452,6 @@ dom-walk@^0.1.0:
resolved "https://registry.yarnpkg.com/dom-walk/-/dom-walk-0.1.2.tgz#0c548bef048f4d1f2a97249002236060daa3fd84"
integrity sha512-6QvTW9mrGeIegrFXdtQi9pk7O/nSK6lSdXW2eqUspN5LWD7UTji2Fqw5V2YLjBpHEoU9Xl/eUWNpDeZvoyOv2w==
dotenv@^8.2.0:
version "8.2.0"
resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.2.0.tgz#97e619259ada750eea3e4ea3e26bceea5424b16a"
integrity sha512-8sJ78ElpbDJBHNeBzUbUVLsqKdccaa/BXF1uPTw3GrvQTBgrQrtObr2mUrE38vzYd8cEv+m/JBfDLioYcfXoaw==
drbg.js@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/drbg.js/-/drbg.js-1.0.1.tgz#3e36b6c42b37043823cdbc332d58f31e2445480b"