Short Description
Automated build for dorry-arm-market
Full Description
Dorry Arm Market
- Dorry Arm Market serves the market of Dorry Platform on arm and provides a set of apis for user management.
- It uses tornado as the web framework and requires Python version 3 or above.
Environment Setup
- To get the source code, run
git clone https://bitbucket.org/MatchboxDorry/dorry-arm-market.git
. - This project requires Python 3, please make sure Python 3 is installed on your machine. Visit Python for more information.
cd dorry-arm-market
sudo apt-get -y update && sudo apt-get -y upgrade
sudo apt-get install python3-pip
- Run
pip3 install -r requirements
to install requirements.
Start the Server
- Run
python3 server.py
to start the server. The server will be running on port 15000.
Start the server with a Docker container
- Run
docker build -t dorry-arm-market .
to build the image. - Run
docker run --restart=always -p 15000:15000 --net=host -h <host> --name dorry_market -d dorry-arm-market
to start the container.
Start the database with a Docker container
- Run
docker run --restart=always -p 28000:27017 --name dorry_market_db -d mongo
to start the database.
Testing
- A testing environment is required for testing. If you do not have a server running on 15000 and a mongo database running on 28000, please set up the environment with the steps below.
- To set up the environment, run
docker run -p 28000:27017 --name dorry_market_db_test --restart=always -d mongo
andpython3 server.py
. - To run the tests, run
python3 test.py
. - To delete the mongo database for testing, run
docker stop dorry_market_db_test && docker rm dorry_market_db_test
.
Documentation
- This project uses Sphinx and Read the Docs to generate the documentation.
- This video Sphinx & Read the Docs provides detailed explanation on how to generate and serve a documentation with Sphinx and Read the Docs.
- Visit Sphinx and Read the Docs for more information.