To get the project just type
git clone https://github.com/labdii/pilot
To setup the python environment we'll use virtualenv
For apt-get based systems
sudo apt-get install python3-pip
Then install virtualenv
pip3 install virtualenv
NOTE: We are using Python 3.x
Now let's create the environment and activate it
virtualenv -p python3 <name_of_enviroment>
source <name_of_enviroment>/bin/activate
Now go inside the project folder and install dependencies
cd pilot
pip install -r requirements.txt
Ensure .env file with environmental variables exists and is placed in the root folder.
MONGODB_URI=<mongodb uri>
MONGODB_DBNAME=<database name>
Grant permissions and run the script
sudo chmod +x start_dev.sh
./start_dev.sh
If you want to use gunicorn
# Using just 1 worker. You can replace the 1 for any number of workers
gunicorn -w1 app:app
- Write a build env script