Monolithic model-view-controller full-stack web application built with Python, Flask, SQL Alchemy, MySQL, Jinja, and Bootstrap. Application Server hosted on AWS EC2 with Ubuntu, Gunicorn, and Nginx. MySQL Database on AWS RDS. Redis hosted on AWS Elasticache. CI/CD with Jenkins and AWS CodeDeploy
python3
and python3-pip
are installed on your system$ pipenv shell
$ pipenv install -r requirements.txt
<value>
in the next stepAPI_KEY=<value>
$ python application.py
$ export FLASK_APP=application.py
$ flask run
finances.db
db.create_all()
below Initialize Schemas
. Once the code runs and the you've verified the database exists, remove db.create_all()
$ python
$ from application import db
$ db.create_all()
CREATE TABLE
command (one at a time):CREATE TABLE users (
id INTEGER PRIMARY KEY AUTO_INCREMENT,
username VARCHAR(50) UNIQUE,
hash VARCHAR(200) NOT NULL,
cash INTEGER
);
CREATE TABLE portfolio (
id INTEGER PRIMARY KEY AUTO_INCREMENT,
user_id INTEGER,
symbol VARCHAR(5),
current_shares INTEGER
);
CREATE TABLE bought (
id INTEGER PRIMARY KEY AUTO_INCREMENT,
buyer_id INTEGER,
time VARCHAR(100),
symbol VARCHAR(5),
shares_bought INTEGER,
price_bought FLOAT
);
CREATE TABLE sold (
id INTEGER PRIMARY KEY AUTO_INCREMENT,
seller_id INTEGER,
time VARCHAR(100),
symbol VARCHAR(5),
shares_sold INTEGER,
price_sold FLOAT
);
Copyright Notice and Statement: currently not offering any license. Permission only to view and download. Refer to choose a license for more info.