Coder Social home page Coder Social logo

pengqiu2008 / dashboard Goto Github PK

View Code? Open in Web Editor NEW

This project forked from salimhamed/dashboard

0.0 2.0 0.0 2.36 MB

A simple dashboarding web application built using Flask and Bootstrap.

Python 25.49% JavaScript 44.45% CSS 1.06% HTML 28.88% Mako 0.13%

dashboard's Introduction

Overview

This is a simple dashboarding application built using Flask and Bootstrap. The application has been tested with Python 2.7. It's ready to deploy with AWS Elastic Beanstalk.

You can view the applcation at flaskdashboard.info using the following user credentials:

Installation

  1. Clone the repository
git clone https://github.com/salimhamed/dashboard.git
  1. Create a virtualenv in the project directory
cd dashboard
virtualenv venv
source venv/bin/activate
  1. Install dependencies
pip install -r requirements.txt
  1. Create database
./manage db_rebuild
  1. Run tests
./manage.py test
  1. Start development server
./manage.py runserver

Database Operations

PostgreSQL Database Operations

  1. pg_ctl is a utility to initialize, start, stop, or control a PostgreSQL server.
  • pg_ctl status -D DATADIR shows the status of a PostgreSQL database.
  • pg_ctl start -D DATADIR starts the PostgreSQL server
  • pg_ctl stop -D DATADIR stops the PostgreSQL server.
  • pg_ctl stop -D DATADIR -m fast immediately stops the PostgreSQL server rather than waiting for session-initiated disconnection.
  1. postgres is the PostgreSQL server.
  • postgres -D DATADIR starts the PostgreSQL server.
  1. psql is the PostgreSQL interactive terminal.
  • psql -d DATABASE connects to a given database.
  • psql -l lists all available databases.

Destroy and Rebuild Database

  1. The positional argument 'db_rebuild' will delete any existing sqlite database and create a new devlopment database populated with fake data.
./manage db_rebuild

Database Migrations

  1. Create an automatic migration upgrade script
./manage db migrate -m "<migration message>"
  1. Apply the migration upgrade script (note, upgrade script should be reviewed before applying changes)
./manage db upgrade

Resources

Flask Extensions

dashboard's People

Contributors

salimhamed avatar

Watchers

James Cloos avatar pengqiu2008 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.