Skip to content

Commit

Permalink
Merge branch 'develop' into alias_deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
kesar committed May 18, 2019
2 parents 2893888 + aa454d9 commit cdf2320
Show file tree
Hide file tree
Showing 19 changed files with 744 additions and 341 deletions.
199 changes: 199 additions & 0 deletions Deployment_Procedure.md
@@ -0,0 +1,199 @@
## 1. Account Creation and Set Authority

### `eosio.forum`

```
owner: eosio
active: eosio
```

### `bet.bos`

```
owner: eosio@active
active: (7/25) bet
```

### `escrow.bos`

```
owner: eosio@active
active:
escrew.bos@eosio.code
bet.bos@active
eosio@active
```

### `auditor.bos`

```
owner: eosio@active
active:
auditor.bos@eosio.code
bet.bos@active
eosio@active
auditors
```





## 2. Set Contract and Set Permission

Create `escrow.bos`, set contract, and set permission

Create `auditor.bos`, set contract, and set permission

Create `eosio.forum`, set contract, and set permission



### 2.1 Create 4 Accounts

```
cleos -u https://bos.eoshenzhen.io:9443 system newaccount eosio bet.bos EOS7QA2LEZFjTEs43snHMmtVabCvtUDzLChbFdQ9TP717LwDyQJbF EOS5oNwXoHRXLCrzYLqkRK7wx1UvwZZnGJGcQz6bXPEYv1mRhBbMf --stake-cpu "10.0000 BOS" --stake-net "10.0000 BOS" --buy-ram "20.0000 BOS" -p eosio -s -j -d > newacct_betbos.json
cleos -u https://bos.eoshenzhen.io:9443 system newaccount eosio escrow.bos EOS7oPEjU1nGKNoN7iCGmuj67P5Wd5vFCQicvpHNjE3Jhfr6Hz4hk EOS7h6ASi8oDqtgNa8wbgETMVvn4EkqA9bopLcjoDdVuoee4CKgRT --stake-cpu "10.0000 BOS" --stake-net "10.0000 BOS" --buy-ram "20.0000 BOS" -p eosio -s -j -d > newacct_escrowbos.json
cleos -u https://bos.eoshenzhen.io:9443 system newaccount eosio auditor.bos EOS5UEAtJAwTqX3puiitoTPEbRiXxkMnG3xBJTK5x7i4ND62pRzGG EOS54wzoGXqcgUDsZxDvW4q39UBL4VNC37dD7NjE392rxaht9eBTB --stake-cpu "10.0000 BOS" --stake-net "10.0000 BOS" --buy-ram "20.0000 BOS" -p eosio -s -j -d > newacct_auditorbfos.json
cleos -u https://bos.eoshenzhen.io:9443 system newaccount eosio eosio.forum EOS5Qqi6f4atV3sXWBxK6MsK53ELJ2cnbo3KZRnu54X3kgdJgR6u2 --stake-cpu "10.0000 BOS" --stake-net "10.0000 BOS" --buy-ram "20.0000 BOS" -p eosio -s -j -d > newacct_eosioforum.js
```



### 2.2 multisig propose_trx

```
cleos -u https://bos.eoshenzhen.io:9443 multisig propose_trx createbetbos bppermission.json newacct_betbos.json pursonchen22
cleos -u https://bos.eoshenzhen.io:9443 multisig propose_trx createescrow bppermission.json newacct_escrowbos.json pursonchen22
cleos -u https://bos.eoshenzhen.io:9443 multisig propose_trx createaudito bppermission.json newacct_auditorbfos.json pursonchen22
cleos -u https://bos.eoshenzhen.io:9443 multisig propose_trx
createforum bppermission.json newacct_eosioforum.json pursonchen
```





### 2.3 BP APPROVE

```
cleos -u https://bos.eoshenzhen.io:9443 multisig approve createbetbos '{"actor":"BP_name","permission":"active"}' -p BP_name
cleos -u https://bos.eoshenzhen.io:9443 multisig approve createaudito '{"actor":"BP_name","permission":"active"}' -p BP_name
cleos -u https://bos.eoshenzhen.io:9443 multisig approve createforum '{"actor":"BP_name","permission":"active"}' -p BP_name
cleos -u https://bos.eoshenzhen.io:9443 multisig approve createescrow '{"actor":"BP_name","permission":"active"}' -p BP_na
```



### 2.4 multisig exec proposal

```
cleos -u https://bos.eoshenzhen.io:9443 multisig exec pursonpurson createbetbos -p pursonpurson@active
cleos -u https://bos.eoshenzhen.io:9443 multisig exec pursonpurson createaudito -p pursonpurson@active
cleos -u https://bos.eoshenzhen.io:9443 multisig exec pursonpurson createescrow -p pursonpurson@active
cleos -u https://bos.eoshenzhen.io:9443 multisig exec pursonpurson createforum -p pursonpurson@acti
```



## 3. Deploy 3 Contracts

### `eosio.forum`, `auditor.bos`, `escrow.bos`

```
cleos -u https://bos.eoshenzhen.io:9443 set contract eosio.forum eosio.forum -p eosio.forum@active
cleos -u https://bos.eoshenzhen.io:9443 set contract auditor.bos auditor.bos -p auditor.bos@active
cleos -u https://bos.eoshenzhen.io:9443 set contract escrow.bos escrow.bos -p escrow.bos@activ
```

## 4. Create Account `bet.bos`

### 4.1 active 7/25

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission bet.bos active '{"threshold":7,"keys":[],"waits":[],"accounts":[{"permission": {"actor":"kesaritooooo","permission":"active"},"weight": 1}, {"permission": {"actor":"chengsong111","permission":"active"},"weight": 1}, {"permission": {"actor":"tyeeeeeeeeee","permission":"active"},"weight": 1}, {"permission": {"actor":"iwangyunpeng","permission":"active"},"weight": 1}, {"permission": {"actor":"igor","permission":"active"},"weight": 1}, {"permission": {"actor":"mybabylilian","permission":"active"},"weight": 1}, {"permission": {"actor":"bosmasterdin","permission":"active"},"weight": 1}, {"permission": {"actor":"vitojingchen","permission":"active"},"weight": 1}, {"permission": {"actor":"sheldonhuang","permission":"active"},"weight": 1}, {"permission": {"actor":"catherine521","permission":"active"},"weight": 1}, {"permission": {"actor":"larosenonaka","permission":"active"},"weight": 1}, {"permission": {"actor":"winlinwinlin","permission":"active"},"weight": 1}, {"permission": {"actor":"mike","permission":"active"},"weight": 1}, {"permission": {"actor":"rohananswers","permission":"active"},"weight": 1}, {"permission": {"actor":"breaktherule","permission":"active"},"weight": 1}, {"permission": {"actor":"angelcats123","permission":"active"},"weight": 1}, {"permission": {"actor":"leonsunlucky","permission":"active"},"weight": 1}, {"permission": {"actor":"angeliazhang","permission":"active"},"weight": 1}, {"permission": {"actor":"ckqdbwzpmtqz","permission":"active"},"weight": 1}, {"permission": {"actor":"blokspartner","permission":"active"},"weight": 1}, {"permission": {"actor":"eric","permission":"active"},"weight": 1}, {"permission": {"actor":"puritychen22","permission":"active"},"weight": 1}, {"permission": {"actor":"victorleeosx","permission":"active"},"weight": 1}, {"permission": {"actor":"deadlock2bos","permission":"active"},"weight": 1}, {"permission": {"actor":"deniscarrier","permission":"active"},"weight": 1]}' -p bet.bos@owner
```

### 4.2 set owner key to `eosio`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission bet.bos owner '{"threshold":1,"keys":"","accounts":[{"permission": {"actor":"eosio","permission":"active"},"weight":1}]}' -p bet.bos@owner
```



## 5. Create Account `eosio.forum`

### 5.1 set active and owner key to `eosio`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission eosio.forum active '{"threshold":1 ,"keys":[],"waits":[],"accounts":[{"weight": 1, "permission": {"actor": "eosio", "permission": active}}]}' -p eosio.forum@owner
cleos -u https://bos.eoshenzhen.io:9443 set account permission eosio.forum owner '{"threshold":1 ,"keys":[],"waits":[],"accounts":[{"weight": 1, "permission": {"actor": "eosio", "permission": active}}]}' -p eosio.forum@owner
```





## 6. auditor.bos

### 6.1 set active key to `eosio`, `bet.bos` and `auditors`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission auditor.bos active '{"threshold":1 ,"keys":[],"waits":[],"accounts":[{"weight": 1, "permission": {"actor": "eosio", "permission": active},{"permission": {"actor": "bet.bos", "permission": "active"}, "weight": 1},{"permission": {"actor": "auditor.bos", "permission": "active"}, "weight": 1}]}' -p auditor.bos@active
```



### 6.2 set owner key to `eosio`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission auditor.bos owner '{"threshold":1 ,"keys":[],"waits":[],"accounts":{"weight": 1, "permission": {"actor": "eosio", "permission": active}}}' -p auditor.bos@owner
```



## 7. escrow.bos

### 7.1 set active key to `eosio`, `bet.bos` and `auditors`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission auditor.bos active '{"threshold":1 ,"keys":[],"waits":[],"accounts":{"weight": 1, "permission": {"actor": "eosio", "permission": active}},{"permission": {"actor": "bet.bos", "permission": "active"}, "weight": 1},{"permission": {"actor": "escrow.bos", "permission": "active"}, "weight": 1},}' -p auditor.bos@active
```


### 7.2 set owner key to `eosio`

```
cleos -u https://bos.eoshenzhen.io:9443 set account permission auditor.bos owner '{"threshold":1 ,"keys":[],"waits":[],"accounts":{"weight": 1, "permission": {"actor": "eosio", "permission": active}}}' -p auditor.bos@owner
```
4 changes: 0 additions & 4 deletions Execution_Procedure.md
Expand Up @@ -9,8 +9,6 @@ alias bosc= "eosc -u https://api.boscore.io"

## 1. Proposal Submission and Referendum ([eosio.forum](https://github.com/boscore/referendum/tree/master/contracts/eosio.forum))

![img](https://uploader.shimo.im/f/K0qO5RiIfVoFNxbU.png!thumbnail)


Proposer proposes proposal
```
Expand Down Expand Up @@ -45,8 +43,6 @@ bosc tx create auditor.bos voteauditor '{"voter":"<VOTER>","newvotes":["<CANDIDA

## 3. BET/BPs Review and Approve ([escrow.bos](https://github.com/boscore/referendum/tree/master/contracts/escrow.bos))

![img](https://uploader.shimo.im/f/0YbGxhOpqG4U5ObT.png)



### Proposal Approved
Expand Down
56 changes: 13 additions & 43 deletions README.md
@@ -1,6 +1,9 @@
# BOS Ecosystem Program (Referendum & WPS)
[Proposal Structure Example](https://github.com/boscore/referendum/blob/master/Proposal%20Structure%20Example.md)
[Referendum Deployment Procedure](https://github.com/boscore/referendum/blob/master/Execution_Procedure.md)
[中文版本](./README_cn.md)
- [Proposal Structure Example](https://github.com/boscore/referendum/blob/master/Proposal%20Structure%20Example.md)
- [Deployment Procedure](https://github.com/boscore/referendum/blob/master/Deployment_Procedure.md)
- [Execution Procedure](https://github.com/boscore/referendum/blob/master/Execution_Procedure.md)


# 1. Background

Expand All @@ -9,49 +12,16 @@ BOSCore will set up an environmental fund of 100 million BOS for infrastructure
After this proposal is approved, BOSCore will deposit 100 million BOS into a designated account, which will be managed by BPs and used according to community referendum.

# 2. BOS Executive Team
Founded by several senior members of the EOSIO community, each member is veteran in the blockchain industry, involving wallets, mining pools, exchanges, and many other companies. The members have extensive experience in the field of Bitcoin, Ethereum and EOS. Each member is committed to blockchain technology, improving human productivity and freedom.
Details: https://www.boscore.io/en/team.html


# 3. Program Goals
* Attracting and incentivizing developers or teams
* Letting more communities get involved
* Accelerating the evolution of EOSIO technology
* Prospering the EOSIO Ecosystem
# 4. Main Missions
The program is mainly to provide resources for the following work:
* Core code development
* EOSIO Ecosystem Application Tool
* EOSIO's community development and motivation The program establishes the next form of community-driven collaboration for BOS. These funds will be used to advance the support and incentives required for the development of BOS and other EOSIO infrastructure projects.
# 5. Proposal method and fund payment
All BOS community participants can submit proposals while staking 100 BOS to submit a proposal to the referendum contract.
### The proposal needs to include:
* The name of the task
* Features of the task
* The deadline of task completion will start from the date the referendum is approved (relative to the referendum approved time)
* The amount of the incentives, and receipt account (the account can be changed later)
### The conditions for the approved proposal:
* The votes from token holders is not less than 40% of BP votes from token holders when the proposal was initiated.
* The ratio of approved votes/disapproved is greater than 1.5.
* The above conditions last for 20 days.
### BOS Auditor:
* Stake 100,000 BOS
* Have an understanding of the major public chain consensus mechanisms
* You must make your BOS account name publicly available and other valid contacts, create your own homepage or social accounts. (Do not disclose personal sensitive information)
* If cheating occurs, the qualification will be immediately submitted for cancellation by BPs. The staked BOS will be transferred to Foundation account and will be returned back after one year locking.
* Votes are counted at the end of each quarter, the top 5 are elected, and up to 20 auditors.
* The auditor has a one-year term and will need re-election after the expiration.
### Conditions for being an auditor:
* The votes from token holders is not less than 3% of BP votes from token holders when the proposal was initiated
* The ratio of approved votes/disapproved is greater than 1.5
* The above conditions last for 20 days.
# 6. Fund payment process points:
1. The community chooses suitable proposals for fund support by referendum.
2. The amount of a single proposal incentives cannot exceed 1 Million BOS. Generally, after the deadline expires, the proposal incentives are automatically paid.
3. 10 days before the deadline, if the BOS Executive Team believes that the task has not been effectively executed, it has the right to temporarily freeze the payment of funds and submit the payment proposal to BP vote. BOSCore Executive Team checkpoints:
* estcase coverage, whether the test passed?
* Whether the coding quality is up to standard?
* Whether the specified functions in the proposal are fully implemented?
* Is there a security bug?
1. If the fund payment is frozen, the BOS independent auditor needs to publish the review within 7 days, make independent judgment in the contract, and issue a link to the relevant investigation report.
2. Within two weeks after the auditor’s comments, BP needs to make a decision. If more than 2/3+1 active BPs agree to continue to pay the incentives, it will continue to pay 90% of the incentives; Otherwise the payment will be rejected.
3. The 40% of the incentives for the proposal are equally divided between the auditors who agree with the majority of the BPs and the BPs who voted.

![图片](https://github.com/boscore/referendum/blob/master/flow.png)


# More Details:
- English: [BOS Ecosystem Program(Referendum & WPS).md](https://github.com/boscore/Documentation/blob/master/Referendum_WPS/BOS%20Ecosystem%20Program(Referendum%20%26%20WPS).md)
- Chinese: [Referendum_WPS/BOS生态基金方案.md](https://github.com/boscore/Documentation/blob/master/Referendum_WPS/BOS生态基金方案(含公投%26WPS).md)
59 changes: 10 additions & 49 deletions README_cn.md
@@ -1,60 +1,21 @@
# BOS生态系统计划(公民投票和WPS)
[提案结构范例](https://github.com/boscore/referendum/blob/master/Proposal%20Structure%20Example_cn.md)
- [提案结构范例](https://github.com/boscore/referendum/blob/master/Proposal%20Structure%20Example_cn.md)
- [Deployment Procedure](https://github.com/boscore/referendum/blob/master/Deployment_Procedure.md)
- [Execution Procedure](https://github.com/boscore/referendum/blob/master/Execution_Procedure.md)

## 1.  背景
## 1. 背景

BOS创始团队将会设立1亿BOS的生态基金用于BOS开发激励提案。1亿BOS将会存入指定账户,按照社区公投方式来使用该笔资金。
BOS的基础设施搭建者、协议标准制定者、代码优化者、生态建设者、和其他EOSIO生态的贡献者都可以申请BOS生态基金。
*此方案中出现的投票非特殊说明均是指 eosio.token 合约下symbol为BOS的Token.*
## 2.  BOS项目团队(BET, BOSCore Executive Team)
由EOSIO社区多个资深成员成立,每个成员都是区块链行业的早期创业者,涉及了钱包、矿池、交易所等诸多业态。基金成员经历过从价值承载的比特币,运行智能合约的以太坊,再到企业级应用的EOS,每个成员都致力于区块链技术落地,提高人类生产力以及自由的事业。
## 2. BOS项目团队(BET, BOSCore Executive Team)
https://www.boscore.io/team.html

## 3. 提案目标
* 吸引有优秀开发者或者团队
* 让更多的社区力量参与进来
* 加速EOSIO技术的不断进化
* 繁荣EOSIO生态
## 4.  主要任务
生态基金主要在为以下工作提供资源:
* 核心代码的研发工作
* EOSIO生态类应用工具
* EOSIO的社区发展与激励

本提案用于建立BOS下一步的社区化合作的形式。这些资金会用于推进BOS以及其他EOSIO基础项目发展所需要的支持和激励方面。
## 5、提案与公审要点
 BOS社区参与者均可以提出议案,参与者需要抵押100 BOS向公投合约提出提案。
提案需要包括:
* 提案的名称
* 提案功能内容描述
* 提案的最晚完成提交时间(公投通过以后起算)
* 提案所需金额及收款账户(收款账户后续可改)

提案通过的条件:
1. 参与投票数量不少于提案发起时参与BP投票数量的 40%
2. 支持票/反对票的比率大于 1.5
3. 以上条件持续 20 天成立

BOS评审员
* 抵押10万BOS
* 对各大公链共识机制有了解
* 公开自己的BOS账户以及其他有效联系方式,建立自己的主页或社交账户地址(非隐私信息)
* 如有作弊发生,资格立即被BP多签取消,并将抵押转入到基金账户,锁仓一年后归还
* 每季度末统计一次投票,前5名当选,最多20名评审员
* 评审员任期一年,期满需再次发起投票

成为评审员的条件:
1. 参与投票数量不少于提案发起时参与BP投票数量的 3%
2. 支持票/反对票的比率大于 1.5
3. 以上条件持续 20 天成立
## 6、提案流程要点:
1. 社区以公投方式选出合适的提案来进行基金支持
2. 单笔提案激励额度不得大于100万BOS;正常情况下提案到期后,激励金由收款账户申领
3. 最晚交付日前10天,若 BET 认为该任务未被有效执行,则有权暂时冻结资金支付,并将该支付的议案提交至节点表决。BET 检查点:
1. Testcase覆盖程度
2. 编码质量是否达标
3. 提案功能实现程度
4. 安全漏洞相关
4. 若资金支付被冻结,BOS独立评审员需要在7天内发表审查意见,并在合约中做出独立判断,并发布判断的相关调查报告的链接。
5. 评审员发布意见以后2周内,BP可以参考评审员的决定,若超过2/3加1的出块节点同意继续支付提案激励,则继续支付90%的提案激励,反之则否决支付。
6. 提案激励的40% 平分给和多数节点做出一致结论的评审员 和 参与表决的BP。如果最后BP没有通过,则全部激励转回基金账户。

![图片](https://github.com/boscore/referendum/blob/master/flow_cn.png)

## 4. 详情
[Referendum_WPS/BOS生态基金方案.md](https://github.com/boscore/Documentation/blob/master/Referendum_WPS/BOS生态基金方案(含公投%26WPS).md)

0 comments on commit cdf2320

Please sign in to comment.