Flask Bootstrap Anywhere screenshot

Flask Bootstrap Anywhere

Author Avatar Theme by Hrishikeshrt
Updated: 10 Feb 2023
24 Stars

Quickly set up a web-based application using Flask styled with Bootstrap and deploy on PythonAnywhere

Categories

Overview

Flask-Bootstrap-Anywhere is a skeleton application written in Python using the Flask microframework. It provides support for user registration, login, session management, password recovery, password reset, and database connection. These features are achieved through the use of Flask-Security-Too and various Flask extensions like Flask-Login and Flask-WTF. The frontend styling is done using Bootstrap. This application aims to save developers’ effort by integrating commonly used plugins for commonly required tasks.

Features

  • User Management: Registration, login, session management, password recovery
  • Database Support: MySQL, SQLite, MongoDB (incomplete)
  • Mail: SMTP access for password recovery and welcome mail after registration
  • Migrations: Powered by Flask-Migrate for database migrations
  • Deployment: Support for Git-powered release on PythonAnywhere
  • Frontend: Bootstrap-powered clean frontend with elegant themes from Bootswatch
  • Ability to change themes on the fly
  • Sample Frontend Components (TODO)

Installation

  1. Install the required packages from the requirements.txt file.
  2. Copy the settings.sample.py file to settings.py and update it as required. Most settings can also be specified through environment variables.
  3. Run the application using the command specified in the documentation. Alternatively, other WSGI-based deployments like gunicorn are also possible.
  4. To use a different database backend, update the credentials in settings.py or through environment variables. By default, SQLite3 is used, but MySQL and PostgreSQL are also supported.
  5. If SMTP credentials are added, mail support will be enabled for password recovery and welcome emails. The contents of these emails can be modified by editing the templates in templates/security/email.
  6. For deployment on PythonAnywhere, create a free account on their website, generate a token, and clone your repository on the server. Follow the provided instructions for set-up.

Summary

Flask-Bootstrap-Anywhere is a versatile Python application built with Flask for small to medium-sized projects that require user management. It provides essential features like registration, login, and session management, with additional support for password recovery, password reset, and database connectivity. The application is easily deployable on PythonAnywhere and offers a clean and elegant frontend powered by Bootstrap and Bootswatch themes. With its flexible architecture, developers can customize its features and expand its capabilities according to their project requirements.