Skip to content

A template application for the Python/Flask - MongoDB environment

Notifications You must be signed in to change notification settings

samardzicnenad/flongo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flongo

Description:

Flongo is a "template application" for the Python/Flask - MongoDB environment.
It also provides a simple user management system that serves the following API endpoints:

  • / (it will redirect to /login or /index depending on the existence of the active user session)
  • /signup
  • /login and
  • /index

There is also an auxiliary endpoint:

  • /info

which is not actually a part of the project, but exists in order to provide additional info to the application users.

Once a user signs up and logs in, the session cookie is created and it is valid for 30 minutes

Usage:

Running

$ docker-compose up

command will pull images and build, create, start and link the container instances for the services defined in the docker-compose.yml file, resulting in flongo application running on:

http://0.0.0.0 (and/or http://0.0.0.0:80)
  • docker-compose.yml defines three services that will get started and linked:
    • flongo (python:2.7.12 with the following dependencies: flask, pymongo, libsass)
    • nginx
    • mongo (mongo:3.3.10)

Data model specifics:

The application stores data in three collections:

  • users
    • usernames and email addresses are unique
  • sessions
    • the list of the most recent user sessions
  • past_sessions
    • the list of the past user sessions

Additional elements:

The application uses:

  • Gunicorn - application server
  • Nginx - front end reverse proxy
  • Jinja2 - templating engine and
  • libsass - CSS preprocessor

Notes:

  • during the login and signup processes, non ascii characters will be ignored

About

A template application for the Python/Flask - MongoDB environment

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published