Stay hungry,Stay foolish

0%

flask-test.md

Flask 安装

创建虚拟环境

1
2
cd $workdir
python3 -m venv venv

激活虚拟环境

1
. venv/bin/activate

Flask 安装

1
pip install Flask

运行

1
2
export FLASK_APP=demo.py
flask run --host=0.0.0.0

调试模式

1
export FLASK_ENV=development