Running on a Host
Running a surplus auction-keeper on a host
Prerequisites
Python 3.6+
Clone:
git clone https://github.com/reflexer-labs/auction-keeper.git
cd auction-keeper
git submodule update --init --recursiveInstall:
This creates a virtual environment and installs requirements:
./install.sh
1. Start virtualenv
source _virtualenv/bin/activate
2. Modify model file as needed
A basic surplus auction bidding model can be found in models/surplus_model.py. This model retrieves the latest FLX/USD price from coingecko and will automatically place bids in an auction.
You probably want to modify the following variables in models/surplus_model.py:
STARTING_FLX_MULTIPLIER: The maximum acceptable FLX price to use when bidding. This value will be used when bidding on a new auction with no previous bids. Default: 1.50 meaning the maxiimum price to accept for FLX(in RAI) is 150% of the current FLX/USD market price
MINIMUM_FLX_MULTIPLIER: The minimum acceptable FLX price to use when bidding. Default: 1.10 meaning the minimum price to accept for FLX(in RAI) is 110% of the current FLX/USD market price
MY_BID_INCREASE: The amount of bid increase(in FLX) to make when outbidding another bidder. If value is less than the auction house' bidIncrease, then it will use the auction house setting. Example: A value of 1.10 will create bid increases of 10%. Note: Current bidIncrease on mainnet is 1.03. Default: 1.03
Ensure script is executable
chmod +x surplus_model.py
For more information about bidding models, see Bidding Models
3. Modify keeper run file
Modify the following variables in run_surplus_keeper_host.sh
KEEPER_ADDRESS - the keeper's address. It should be in checksummed format (not lowercase).
ETH_RPC_URL - the URL of your ethereum RPC connection
KEYSTORE_FILE - your Ethereum UTC JSON keystore filename
For more information about this keystore format and how to generate them, check:
GAS_MAXIMUM -maximum gas price, in GWEI
Ensure script is executable
chmod +x run_surplus_keeper_host.sh
4. Start the keeper and enter your keystore file password
./run_surplus_keeper_host.sh
Surplus Auction Output
Start a Surplus Auction
If enough surplus exists in the system, the surplus auction-keeper will call auctionSurplus to start a surplus auction.
Bid on a Surplus Auction
If the surplus auction-keeper has FLX, it will bid on surplus auctions by calling increaseBidSize
Full Log Output
Last updated
Was this helpful?