Created
January 23, 2020 01:33
-
-
Save jyntran/080f012b5d515caff8a763f143148f16 to your computer and use it in GitHub Desktop.
Flask Setup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt update | |
sudo apt install python3-pip python3-dev build-essential libssl-dev libffi-dev python3-setuptools | |
sudo apt install python3-venv | |
cd ~/myproject | |
python3.6 -m venv myprojectenv | |
source myprojectenv/bin/activate | |
pip install wheel | |
pip install uwsgi flask | |
pip install requests | |
sudo ufw allow 5000 | |
python myproject.py | |
uwsgi --socket 0.0.0.0:5000 --protocol=http -w wsgi:app | |
deactivate |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment