This is the web app repository for the convention logistics tracker. Inside this repo you will find:
- An Angular2 frontend
- A Flask backend
- A docker configuration for deploying to production
The backend is based off https://github.com/ansrivas/angular2-flask
-
backend
directory contains the flask backend with simple authentication methods -
front
directory contains the angular2 frontend based on angular2-webpack
-
Clone the repo
git clone --depth 1 https://github.com/CLTracker/CLT-webapp.git cd CLT-webapp
-
Install the backend related requirements and run. The following will start a flask-server on
localhost:8080
cd backend sudo pip install -r requirements.txt python run.py
-
Install frontend related dependencies
cd front # install global dependencies npm install webpack-dev-server rimraf webpack typescript -g # install project related dependencies npm install # run server with hot module replacement npm run start:hmr # run server without hot module replacement npm run start
The current build is using nginx
to serve static files. The pre-requisite is to run the following commands and then use docker-compose
- Build the frontend ( production build )
cd front
npm install webpack-dev-server rimraf webpack typescript -g
npm install
npm run build:prod
-
Now, in project root directory execute
docker-compose up
-
Navigate to
http://localhost:3000
and login usingadmin:admin