Skip to content

Latest commit

 

History

History
83 lines (64 loc) · 1.27 KB

README.md

File metadata and controls

83 lines (64 loc) · 1.27 KB

applications

An App that helps us process applications for our event

Installation

Step 1:

git clone https://github.com/HackDavis/applications.git
cd applications

Step 2:

pip3 install virtualenv
virtualenv -p python3 venv
venv\Scripts\activate (Windows)
source venv/bin/activate (Unix-like)
cd applications-frontend
npm install
npm run build

# Use "deactivate" to exit virtual environment

Step 3:

python3 start.py -c install

Step 4: Set .env with these default values

FLASK_APP=app.py
FLASK_ENV=development
SECRET_KEY=<complete this>
OAUTHLIB_INSECURE_TRANSPORT=1
DB_USER=<complete this>
DB_HOSTNAME=localhost
DB_PORT=5432
DB_PASSWORD=<complete this>
DB_NAME=<complete this>
GOOGLE_CLIENT_ID=<complete this>
GOOGLE_CLIENT_SECRET=<complete this>
TYPEFORM_TOKEN=<complete this>

Running

python3 start.py

Formatting

python3 start.py -c format

Deployment

# Need to install pm2 for this: http://pm2.keymetrics.io/docs/usage/quick-start/#installation
python3 start.py -c deploy

Useful scripts

Adding an admin

python3 admin.py -c make-admin

Removing an admin

python3 admin.py -c remove-admin

Dropping the database

python3 admin.py -c drop-database