flask env variable

33

import os
print os.environ.get('key')

>>> value
app.config['ENVIRONMENT_VAR'] = "var name here"
(venv) $ export FLASK_APP=microblog.py
export FLASK_APP=application.py

Comments

Submit
0 Comments