-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Docs] Document (non-)custodial staking (#720)
## Summary Follow-up to #716 to document custodial and non-custodial staking configuration. ## Issue ![image](https://github.com/user-attachments/assets/671278e9-911f-43d9-b7eb-e7994b959b72) - #493 ## Type of change Select one or more: - [ ] New feature, functionality or library - [ ] Bug fix - [ ] Code health or cleanup - [x] Documentation - [ ] Other (specify) ## Testing **Documentation changes** (only if making doc changes) - [x] `make docusaurus_start`; only needed if you make doc changes **Local Testing** (only if making code changes) - [ ] **Unit Tests**: `make go_develop_and_test` - [ ] **LocalNet E2E Tests**: `make test_e2e` - See [quickstart guide](https://dev.poktroll.com/developer_guide/quickstart) for instructions **PR Testing** (only if making code changes) - [ ] **DevNet E2E Tests**: Add the `devnet-test-e2e` label to the PR. - **THIS IS VERY EXPENSIVE**, so only do it after all the reviews are complete. - Optionally run `make trigger_ci` if you want to re-trigger tests without any code changes - If tests fail, try re-running failed tests only using the GitHub UI as shown [here](https://github.com/pokt-network/poktroll/assets/1892194/607984e9-0615-4569-9452-4c730190c1d2) ## Sanity Checklist - [ ] I have tested my changes using the available tooling - [ ] I have commented my code - [ ] I have performed a self-review of my own code; both comments & source code - [ ] I create and reference any new tickets, if applicable - [ ] I have left TODOs throughout the codebase, if applicable <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Enhanced command for supplier unstake, improving usability and flexibility. - Introduced new sections in documentation for "Staking types," detailing Custodial and Non-Custodial Staking. - **Documentation** - Expanded configuration documentation with detailed explanations of `owner_address` and `operator_address`. - **Config Updates** - Added `owner_address` and `operator_address` parameters to multiple staking configuration files for improved clarity. - **Improvements** - Streamlined configuration files by removing comments, enhancing clarity on staking roles. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
- Loading branch information
Showing
7 changed files
with
203 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
localnet/poktrolld/config/supplier_stake_config_example.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# This file is used to stake a Supplier or update an existing Supplier's information in the Pocket Network. | ||
# Pocket Network supports two types of staking mechanisms: custodial and non-custodial staking: | ||
# * Custodial staking is the default mechanism, where the owner address (i.e., the account that | ||
# receives the rewards) is the same as the operator address (i.e., the address that operates | ||
# the Supplier). | ||
# * Non-custodial staking is an advanced mechanism, where the owner address is different from | ||
# the operator address. This is useful to avoid overuse of the private key of the | ||
# account that owns the staked funds and receives the rewards. | ||
|
||
# The address of the supplier's owner. This address could stake a new Supplier or | ||
# update any of its properties excluding the operator address which is immutable. | ||
# The account corresponding to this address could also unstake the Suppliers it owns. | ||
# The owner address does not identify the Supplier in the Pocket Network; the same owner | ||
# account can stake multiple Suppliers. | ||
owner_address: pokt19a3t4yunp0dlpfjrp7qwnzwlrzd5fzs2gjaaaj | ||
|
||
# The address of the operator of the Supplier. This address operates the Supplier, | ||
# (i.e., signs relay responses, submits claims and proofs, updates service endpoints, etc.). | ||
# This address can also used to stake a new Supplier or unstake an existing one. | ||
# It uniquely identifies the Supplier in the Pocket Network and cannot be changed | ||
# once the Supplier is created. | ||
# The operator address is optional; if it is empty or not provided, the owner | ||
# address is used as the operator address. | ||
operator_address: pokt19a3t4yunp0dlpfjrp7qwnzwlrzd5fzs2gjaaaj | ||
# NB: The stake amount is exactly 1upokt greater than the value in genesis.json | ||
# so that the stake command causes a state change. | ||
stake_amount: 1000069upokt | ||
# If default_rev_share_percent is omitted, the owner receives 100% of the rewards. | ||
# default_rev_share_percent cannot be empty - it MUST either be omitted completely | ||
# or include at least one item. | ||
default_rev_share_percent: | ||
# The sum of all shares MUST equal 100%. Staking will fail otherwise. | ||
- pokt1mrqt5f7qh8uxs27cjm9t7v9e74a9vvdnq5jva4: 80.5 | ||
- pokt1eeeksh2tvkh7wzmfrljnhw4wrhs55lcuvmekkw: 19.5 | ||
services: | ||
# The endpoint URL for the Anvil service is provided via the RelayMiner. | ||
# The RelayMiner acts as a proxy, forwarding requests to the actual Anvil data node behind it. | ||
# This setup allows for flexible and dynamic service provisioning within the network. | ||
- service_id: anvil | ||
endpoints: | ||
- publicly_exposed_url: http://relayminer1:8545 | ||
rpc_type: JSON_RPC | ||
- service_id: ollama | ||
# Service specific rev share, if rev_share_percent is omitted for a specific | ||
# service, default_rev_share_percent is used. | ||
# The sum of all shares MUST equal 100%. Staking will fail otherwise. | ||
rev_share_percent: | ||
- pokt1mrqt5f7qh8uxs27cjm9t7v9e74a9vvdnq5jva4: 50 | ||
- pokt1eeeksh2tvkh7wzmfrljnhw4wrhs55lcuvmekkw: 50 | ||
endpoints: | ||
- publicly_exposed_url: http://relayminer1:8545 | ||
rpc_type: REST |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters