PowerPool
Search
K
Comment on page

I Want to Become a Keeper

Instructions to register a keeper and install the software
To become a keeper, you have to do the following:
  1. 1.
    Register a keeper in the PowerAgent contract;
  2. 2.
    Install the PowerAgent software;
  3. 3.
    Activate the keeper in the PowerAgent contract.

Keeper registration

Keeper registration, activation, management, stake deposit and withdrawal, compensation withdrawal are done via PowerAgent DApp.
To register a new keeper, follow the instructions below:
  1. 1.
    Navigate to the PowerAgent Web UI for Sepolia or Gnosis.
  2. 2.
    Press “Connect” and connect with your Admin wallet.
  3. 3.
    Press the “Create Keeper” button:
  4. 4.
    Select the most recent agent version. Press the “Create Keeper” button at the bottom:
  5. 5.
    In the keeper creation pop-up window, specify the amount of CVP to stake (no less than 1000) and the Worker address which you created beforehand:
  6. 6.
    An “Unlock” button will light up. Press and confirm the transaction. Afterwards, press “Create keeper”.
  7. 7.
    Afterwards, a keeper will be created, but not activated. Proceed to Installation Section and install the node software.

Node installation

Follow one of guides listed below based on the chosen method:
Standalone
DAppNode

Installation

  • Start with a clean AMD-64 architecture distribution (the code is given for Ubuntu or Debian.
  • Install NodeJS, npm, Docker, and Docker-Compose
  • Navigate to a directory of your choice:
    cd /path/to/the/directory/of/your/choice
  • Clone the standalone repository and cd to it:
    git clone https://github.com/eitelvolkerts/poweragent-standalone
    cd poweragent-standalone
  • Generate the worker keyfile:
    npm i
    node jsongen.js ${YOUR_WORKER_PRIVATE_KEY} ${A_PASSWORD_OF_YOUR_CHOICE}
    Mind that the password will be specified in the config later on, so remember it.
  • Open the config file with a text editor of your choice. For the sake of an example, here we open it with nano
    nano config/main.yaml
  • Fill the file out according to the schema, substituting the variables where needed (numerical values can also be changed, if you so desire). Do not remove ‘’ (quotation marks).
Do not forget to replace ${variable_name} with actual variable.
  • [OPTIONAL] Change the name of the package if you want to run several instances of the PowerAgent on the same machine.
    docker-compose.yaml
    version: "3.9"
    services:
    bot${ANY_UNIQUE_NUMBER_YOU_DESIRE}:
    image: eitelvolkerts/pagentv2:latest
    container_name: bot${ANY_UNIQUE_NUMBER_YOU_DESIRE}
    restart: always
    volumes:
    - ./config:/usr/app/config
    - ./keys:/usr/app/keys
  • Launch the node.
    docker compose up -d
    docker logs -f ${CONTAINER_NAME}
To get the ${CONTAINER_NAME}, execute docker ps and find the container id. If you changed the name of the container, use it instead.

Update

In the folder with the docker-compose.yaml file run:
docker compose down --rmi local
docker pull eitelvolkerts/pagentv2
docker compose up -d

Stop

In the folder with the docker-compose.yaml file run:
docker compose down --rmi local
Afterwards, proceed to the keeper activaton section.

Preparation of the keyfile

On your personal machine, clone this repository:
And execute the following command:
npm i
node jsongen.js ${WORKER_PRIVATE_ADDRESS} ${ANY_PASSWORD}
The generated keyfile will be written into ./keys/ directory.

Installation

In order to locate the PowerAgent package,
  • Switch your IPFS mode to “Local
  • Add the following peers to your DAppNode’s IPFS peer list:
Peers List
1
/ip4/134.122.84.162/tcp/4001/p2p/12D3KooWPJk93THACnrk2LayhBuafoKQTypvssZSQTASU365c8v2
2
/ip4/134.122.84.162/udp/4001/quic/p2p/12D3KooWPJk93THACnrk2LayhBuafoKQTypvssZSQTASU365c8v2
3
/ip4/134.122.84.162/udp/40202/quic/p2p/12D3KooWPJk93THACnrk2LayhBuafoKQTypvssZSQTASU365c8v2
To add peers in DAppNode,
  • Locate the IPFS package in the System Packages menu;
  • Navigate to Peers - Add Connection;
  • Open WebUI;
  • Navigate to the most recent package version either through the installer link or by the IPFS hash. Accept “bypass unsigned restriction” and press install.
  • Fill in the fields when prompted by DAppNode installation UI:
Fields to fill
1
Worker address #This field should contain
2
#the address of your worker.
3
4
Worker key #Remember the keyfile you generated?
5
#Upload it here.
6
7
Worker keyfile password #The password to the keyfile you chose
8
#during generation
9
10
Network #Sepolia or Gnosis, whichever network
11
#you are running on
12
13
Execution client RPC #The Websockets RPC address
14
#of the execution client,
15
#which PowerAgent will connect to.
16
#Look it up in the logs tab
17
#of your execution client you installed earlier.
18
#The default for Sepolia Geth may be like
19
#ws://sepolia-geth.dappnode:8546.
20
21
Agent address #The address of the latest version
22
#of the PowerAgent contract
23
#on the appropriate chain.
24
25
####Leave these empty:####
26
Data source
27
Graph URL
28
API Server
29
Sentry SDK data source name
30
##########################
31
32
Number of blocks to elapse before a tx is resent or dropped #4
33
Max gase price in GWei for tx resending #500
34
Maximal resending attempts number #4
35
Logging level #"debug"
36
37
Accrue reward on the poweragent address
38
#True/False. Default: False.
39
#This value governs whether you accrue the rewards on your worker address or have them transferred immediately upon conferring. Keep in mind that the former option is more gas-efficient.
40
41
Execute tasks when block base fee is greater than max base fee
42
#True/False. Default: False.
43
#This field also accepts a Boolean value. In PowerAgent, the Job owner may set an upper bound on the gas cost for the purposes of reward computation. If you wish to execute the transaction even in the case of such an upper bound depressing your reward amount, select True.
44
45
Max Priority Fee Per Gas
46
#Default: 60000 This field accepts an integer value, to which the max priority fee per gas shall be set.

Update

The package update is as straightforward as possible: locate the new package by its IPFS hash and press “Update”. The configuration from the previous version will persist.

Example configs for standalone installation:

Gnosis
Sepolia Testnet
networks:
data_source: network
enabled:
- gnosis
details:
gnosis:
rpc: '${YOUR_RPC}'
max_priority_fee_per_gas: 6000000
agents:
'0x071412e301C2087A4DAA055CF4aFa2683cE1e499':
executor: pga
keeper_worker_address: '${WORKER_ADDRESS_FOR_WHICH_YOU_GENERATED_THE_KEYFILE}'
key_pass: '${PASSWORD_SPECIFIED_AT_KEYFILE_GENERATION}'
accept_max_base_fee_limit: true
accrue_reward: true
tx_resend_or_drop_after_blocks: 4
tx_resend_max_gas_price_gwei: 1000
tx_resend_max_attempts: 4
gas_price_priority_add_gwei: 100
# data_source: subgraph
# subgraph_url: <https://api.studio.thegraph.com/query/44364/ppav2-rd-sepolia-b11/version/latest>
max_block_delay: 10
resolve_min_success_count: 3
networks:
data_source: network
enabled:
- sepolia
details:
sepolia:
rpc: '${YOUR_RPC}'
max_priority_fee_per_gas: 6000000
agents:
'0xbdE2Aed54521000DC033B67FB522034e0F93A7e5':
executor: pga
keeper_worker_address: '${WORKER_ADDRESS_FOR_WHICH_YOU_GENERATED_THE_KEYFILE}'
key_pass: '${PASSWORD_SPECIFIED_AT_KEYFILE_GENERATION}'
accept_max_base_fee_limit: true
accrue_reward: true
tx_resend_or_drop_after_blocks: 4
tx_resend_max_gas_price_gwei: 1000
tx_resend_max_attempts: 4
gas_price_priority_add_gwei: 100
# data_source: subgraph
# subgraph_url: <https://api.studio.thegraph.com/query/44364/ppav2-rd-sepolia-b11/version/latest>
max_block_delay: 10
resolve_min_success_count: 3

🥳 This concludes the installation + configuration process. Good job!

Keeper activation

After installation, go back to the DApp, open “My Keepers” tab and expand the entry for your newly registered keeper.
The status of the keeper will be “Activating”. Next to it, locate the “Complete” button and confirm the transaction:
Verify that the keeper is active:

Managing Keepers

On the My Keepers tab you can see all your registered keepers; both active and inactive.
Click on the keeper entry to expand the detailed view:
  1. 1.
    Summary tab.
    Here you can see the total number of your keepers, sum of all their CVP stakes and their total earnings in native token.
  2. 2.
    Keeper stats tab.
    Here the key metrics of your keeper are presented: active and pending withdrawal CVP stake, number of jobs completed, and detailed balance.
  3. 3.
    Control tab.
    On this tab you can stake or withdraw CVP for your keeper, as well as withdraw native token earnings.