Skip to content

Commit

Permalink
Merge pull request #58 from DemocracyEarth/dao
Browse files Browse the repository at this point in the history
DAO deploy script
  • Loading branch information
santisiri authored Jan 16, 2021
2 parents 8d01830 + f64b876 commit 7f85d01
Show file tree
Hide file tree
Showing 2 changed files with 2,609 additions and 0 deletions.
36 changes: 36 additions & 0 deletions scripts/dao-deploy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
const deploymentParams = require('../deployment-params');

async function main() {

const [deployer] = await ethers.getSigners();

console.log(
"Deploying DAO with the account:",
deployer.address
);

console.log("Account balance:", (await deployer.getBalance()).toString());

const DAO = await ethers.getContractFactory("Moloch");
console.log("Deploying DAO...");

const dao = await DAO.deploy(
deploymentParams.SUMMONER,
[deploymentParams.TOKEN],
deploymentParams.PERIOD_DURATION_IN_SECONDS,
deploymentParams.VOTING_DURATON_IN_PERIODS,
deploymentParams.GRACE_DURATON_IN_PERIODS,
deploymentParams.PROPOSAL_DEPOSIT,
deploymentParams.DILUTION_BOUND,
deploymentParams.PROCESSING_REWARD
);

console.log("DAO deployed to:", dao.address);
}

main()
.then(() => process.exit(0))
.catch(error => {
console.error(error);
process.exit(1);
});
Loading

0 comments on commit 7f85d01

Please sign in to comment.