Very simple mobile web application written in Python/Flask to upload a picture from a smartphone and overlaying text with current weather using Dark Sky API and GeoIP DB for geolocation and Ratchet HTML/CSS templates to achieve responsiveness
- Create a virtualenv and activate it:
source your_virtualenv_path/bin/activate
- install required modules with
pip install -r requirements.txt
Note that you might need to install libjpeg-dev to be able to install Pillow successfully - # for an API key on https://darksky.net/dev/
- Create two folders to store uploaded/downloaded pictures, preferably mounted on a ram filesystem(tmpfs?)
- Rename
config.sample.py
toconfig.py
- Put your API key and the two folder absolute paths inside config.py
- Launch your application with
FLASK_APP=stupidmeteo.py FLASKR_SETTINGS=config.py flask run
- Have fun!