Flask Login

From Wildsong
Revision as of 22:04, 5 June 2015 by Brian Wilson (talk | contribs)
Jump to navigationJump to search

How to use Flask Login

Try it out with the sample

cd Projects
mkdir FlaskTest
cd FlaskTest
virtualenv .
source bin/activate

pip install flask
pip install flask-wtf
pip install flask-script
pip install flask-login
pip install simple-pbkdf2

Clone source code from bitbucket using sourcetree or git or hg

Create a sample sqlite3 databas

python manage.py initdb

Run the server

python manage.py runserver
* Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
* Restarting with stat

Log in to http://127.0.0.1:5000/ as foo/foo (admins group) or bar/bar (users group) Admins can access the "restricted" tab, users cannot.