Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/step-finance/reward-pool
Staking Program
https://github.com/step-finance/reward-pool
Last synced: about 1 month ago
JSON representation
Staking Program
- Host: GitHub
- URL: https://github.com/step-finance/reward-pool
- Owner: step-finance
- License: apache-2.0
- Created: 2021-08-17T01:11:14.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-04-02T03:46:20.000Z (8 months ago)
- Last Synced: 2024-08-02T06:14:29.397Z (4 months ago)
- Language: JavaScript
- Size: 932 KB
- Stars: 61
- Watchers: 2
- Forks: 38
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-solana-nfts - Step Finance Rewards Pool - finance/reward-pool.svg?style=social) - Step Finance rewards program. "AMM-style", meaning users' funds are pooled and rewards distributed proportionally. Supports rewards in up to 2 different mints. (🥩 Staking)
- awesome-solana-nfts-v2 - Step Finance Rewards Pool - finance/reward-pool.svg?style=social) - Step Finance rewards program. "AMM-style", meaning users' funds are pooled and rewards distributed proportionally. Supports rewards in up to 2 different mints. (🥩 Staking)
README
[![CircleCI](https://circleci.com/gh/step-finance/reward-pool/tree/main.svg?style=svg)](https://circleci.com/gh/step-finance/reward-pool/tree/main)
# Reward Pool
Program for staking and receiving rewards.
## Design Overview
![reward pool account overview](https://github.com/step-finance/reward-pool/blob/main/account-design.png)
*draw.io editable*
## Note
- **This code is unaudited. Use at your own risk.**
## Developing
[Anchor](https://github.com/project-serum/anchor) is used for developoment, and it's
recommended workflow is used here. To get started, see the [guide](https://project-serum.github.io/anchor/getting-started/introduction.html).### Build
```
anchor build --verifiable
```The `--verifiable` flag should be used before deploying so that your build artifacts
can be deterministically generated with docker.### Test
When testing locally, be sure to build with feature "local-testing" to enable the testing IDs. You can do this by editing `programs/step-staking/Cargo.toml` and uncommenting the default feature set line.
```
anchor test
```### Verify
To verify the program deployed on Solana matches your local source code, change directory
into the program you want to verify, e.g., `cd program`, and run```bash
anchor verify
```A list of build artifacts can be found under [releases](https://github.com/step-finance/reward-pool/releases).
### Deploy
To deploy the program, configure your CLI to the desired network/wallet and run
```bash
solana program deploy --programid target/verifiable/reward_pool.so
```I would not suggest using anchor deploy at this time; it wouldn't/couldn't really add much value. Be sure to use `--programid ` to deploy to the correct address.
Note: By default, programs are deployed to accounts that are twice the size of the original deployment. Doing so leaves room for program growth in future redeployments. For this program, I beleive that's proper - I wouldn't want to limit further, but I do see some possibility for growth, but not beyond double.
### Initial Migration
There is no initial migration required with this program.