Dockerized Up Vote Bot application
-
Recursive clone
git clone --recursive https://<<url>>/ZeroPass/Up-Vote-Bot-Dockerized.git
-
Recursive init submodules
git submodule update --init --recursive
-
Build image (be careful on dot at the end:) )
docker build -t up_vote_bot .
-
Run image
docker run -t -p 8080:8080 up_vote_bot
-
Python help
#example of running specific file in the project - you must add PYTHONPATH and LD_LIBRTARY_PATH PYTHONPATH="/app" LD_LIBRARY_PATH="/app/external/abieos-python/external/abieos/build" python /app/chain/eden.py
- Make sure that eden_season_env is updated for every election
- Dont forget to transfer knownUsers table from previous database if you move to the new one ('bot_name' is parameter that tells you which bot has connection with it)
- Database needs to be created before you run the bot (tables will be created automaticaly)
- If you want to update Participant.telegramID in database you should change value if dababase from '-1' to ''(empty string). Value '-1' is there because of optimization (that atomic assets API is not called every time we run the cycle)
-
cd . (go into subfolder)
-
git checkout < last commit >
-
cd ..
-
docker build -t up_vote_bot_release .
-
docker tag up_vote_bot_release cloud/namespace/up_vote_bot_release
-
docker push cloud/namespace/up_vote_bot_release