You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
4 months ago | |
---|---|---|
login | 4 months ago | |
.env | 4 months ago | |
.flaskenv | 4 months ago | |
.gitignore | 4 months ago | |
LICENSE.md | 4 months ago | |
README.md | 4 months ago | |
launch.py | 4 months ago | |
pyproject.toml | 4 months ago | |
requirements-dev.txt | 4 months ago | |
requirements.txt | 4 months ago |
README.md
Flask login template
Describes a simple entrypoint template to build login functionality for the flask application.
⚠️ This application is created for the demo references only.
Tools
Production
- python 3.6, 3.7, 3.8
- sqlalchemy database
- flask web framework
Development
- black code formatter
Quick start
Please make sure your DB is created (
site_users.db
file should be present, for more details please refer to database creation).
git clone git@github.com:vyahello/flask-login-template.git
pip install -r requirements.txt
flask run
Then please open http://localhost:5000
endpoint in the browser.
Development notes
API
This application supports the following API endpoints:
/
orindex.html
- home page of an app/create_user
- creates a fresh user into database/login
- logins the user/logout
- logouts the current user/dashboard
- shows the dashboard page, accessible only for logged in users
Create DB
Please follow the next instructions to create DB from the scratch:
python
Python 3.8.5 (default, Jul 26 2020, 21:03:43)
>>> from login import db
>>> db.create_all()
>>> exit()
ls login/site_users.db
login/site_users.db
Meta
Author – Volodymyr Yahello.
Distributed under the MIT
license. See LICENSE for more information.
You can reach out me at:
- vyahello@gmail.com
- https://twitter.com/vyahello
- https://www.linkedin.com/in/volodymyr-yahello-821746127
Contributing
I would highly appreciate any contribution and support. If you are interested to add your ideas into project please follow next simple steps:
- Clone the repository
- Configure
git
for the first time after cloning with yourname
andemail
pip install -r requirements.txt
to install all project dependenciespip install -r requirements-dev.txt
to install all development project dependencies- Create your feature branch (
git checkout -b feature/fooBar
) - Commit your changes (
git commit -am 'Add some fooBar'
) - Push to the branch (
git push origin feature/fooBar
) - Create a new Pull Request