@1hive/apps-redemptions
v2.0.1
Published
[![CircleCI](https://circleci.com/gh/1Hive/redemptions-app.svg?style=svg)](https://circleci.com/gh/1Hive/redemptions-app) [![Coverage Status](https://coveralls.io/repos/github/1Hive/redemptions-app/badge.svg?branch=master&service=github)](https://coverall
Downloads
19
Keywords
Readme
Redemptions
1Hive's Redemptions app allows Aragon organizations to grant their token holders the right to redeem tokens in exchange for a proportional share of the organizations treasury assets.
🐲 Project Stage: Rinkeby
The Redemptions app has been published to open.aragonpm.eth
on the Rinkeby test network. If you experience any issues or are interested in contributing please see review our open issues.
🚨 Security Review Status: Contracts updated for audit as of commit d61a3b9b419e154894f3dc2ac2eae291612c6519
The code in this repo has not been audited.
How to try Redemptions immediately
We have a Redemptions demo DAO live on Rinkeby!
How to run Redemptions locally
First make sure that you have node, npm, and the Aragon CLI installed and working. Instructions on how to set that up can be found here. You'll also need to have Metamask or some kind of web wallet enabled to sign transactions in the browser.
Git clone this repo.
git clone https://github.com/1Hive/redemptions-app.git
Navigate into the redemptions-app
directory.
cd redemptions-app
Install npm dependencies.
npm i
Deploy a dao with Redemptions installed on your local environment.
npm run start:template
If everything is working correctly, your new DAO will be deployed and your browser will open http://localhost:3000/#/YOUR-DAO-ADDRESS. It should look something like this:
You will also see the configuration for your local deployment in the terminal. It should look something like this:
Ethereum Node: ws://localhost:8545
ENS registry: 0x5f6f7e8cc7346a11ca2def8f827b7a0b612c56a1
APM registry: aragonpm.eth
DAO address: YOUR-DAO-ADDRESS
Currently the only thing deployed on your local testnet is an Aragon DAO with the Redemptions app. In a new terminal navigate to the redemptions-app
directory. Then run this script to deploy some token contracts on your local testnet to interact with.
npm run deploy-tokens YOUR-DAO-ADDRESS
If successful, you will have deployed contracts for ANT, DAI, OMG, and ETH to your local testnet. The terminal will then display the names of the tokens and their addresses on your local testnet. It should look something like this:
Token Address Balance
----- ------------------------------------------ -------
ANT 0x7F381a654914a4C865123B33fD8178efc0Ee5C2D 40
DAI 0xB5Cc76D092aA440087447EBD3A29E9E0b8A4bf9E 100
OMG 0x3d09CfCdD3136aaE7A4B26875A7BAcA0C3d8A03b 14189
ETH 0x0000000000000000000000000000000000000000 0.1
Now if you navigate back to your browser (http://localhost:3000/#/YOUR-DAO-ADDRESS) you'll be able to open the Redemptions app and add one of these tokens to your locally deployed Redemptions app.
How to deploy Redemptions to an organization
Redemptions has been published to APM on rinkeby at redemptions.open.aragonpm.eth
To deploy to an organization you can use the Aragon CLI.
aragon dao install <dao-address> redemptions.open.aragonpm.eth --app-init-args <vault-address> <token-manager-address>
The Redemptions app must have the TRANSFER_ROLE
permission on Vault
and the BURN_ROLE
permission on the Token Manager
.
Contributing
We welcome community contributions!
Please check out our open Issues to get started.
If you discover something that could potentially impact security, please notify us immediately. The quickest way to reach us is via the #dev channel in our team Keybase chat. Just say hi and that you discovered a potential security vulnerability and we'll DM you to discuss details.