Note: virtualenv is a best practice for python, but installation can also be on a user/global level.
Note: Databases must be installed as root/sudo
MINT uses a local SQLite database which requires MySQL setup (running a MySQL server instance is not required). Assuming a Ubuntu 16.04. or later operating system, install:
apt-get install libmysqlclient-dev
Note: bos-mint should be installed as user
You can either install bos-mint via pypi / pip3 (production installation) or via git clone (debug installation). For production use install bos-auto via pip3 is recommended, but the Git master branch is always the latest release as well, making both installations equivalent.
# create virtual environment
virtualenv -p python3 env
# activate environment
# install bos-mint into virtual environment
pip3 install bos-mint
For debug use, checkout from GitHub (master branch) and install dependencies manually:
# modify config-bos-mint.yaml (add your own peerplays node and secret key)
Default configuration only requires the following:
# see bos_mint/config-defaults.yaml for explanation and all possible override values
secret_key: # enter some random string
- # enter your node
Possible override values are :
project_sub_name: The BOS Manual Intervention Module
secret_key: # enter any random string
use: # enter your desired chain
- # enter your node
To run MINT in debug mode use:
bos-mint start --port 8001 --host localhost
The output that you see should contain:
2018-05-1811:56:04,754 INFO :* Running on http://localhost:8001/(Press CTRL+C to quit)
The above setup is basic and for development use. Going forward, a Witness may want to deploy UWSGI with parallel workers for the endpoint.
MINT is purposely run on localhost to restrict outside access. Securing a Python flask application from malicious break in attempts is tedious and would be an ongoing effort.
Important: Recommendation is to access it via a SSH tunnel or through VPN.
Example for SSH tunnel:
Assume bos-mint is running on a remote server accessible via 220.127.116.11 and you have login credentials via SSH (password or private key access). On the local machine that you'll be using to access MINT via a web browser open the tunnel:
After starting MINT use your favourite desktop browser to access it and you'll be asked to enter your Witness key that will be stored encrypted in the local Peerplays wallet.
Note: MINT is not optimized for mobile use yet.
For MINT development use checkout the latest repository from:
GitHub - peerplays-network/bos-mint: The Manual Intervention Module (MINT) provides a web interface for Witnesses to manually intervene in the otherwise fully-automated process of bringing Bookie Events, BMGs, and Betting Markets to the Peerplays blockchain (through bos-auto). This allows Witnesses to handle any edge cases that may arise and cannot be dealt with by bos-auto.