This repository contains two main applications: the back-end (server) and the front-end (user interface). This guide explains how to set up and run them locally.
- Install dependencies:
cd back-end
pip install -r requirements.txt- Create .env file in backend dir with given values:
# PostgreSQL database name
POSTGRES_DB=your_database_name
# PostgreSQL user
POSTGRES_USER=your_database_user
# PostgreSQL password
POSTGRES_PASSWORD=your_database_password
# Optional: PostgreSQL host (default is localhost)
POSTGRES_HOST=localhost
# Optional: PostgreSQL port (default is 5432)
PORT=5432
# Secret key for JWT
JWT_KEY=your_secret_jwt_key
- In order to run app use command
python3 app.py- Install dependencies:
cd front-end pip install -r requirements.txt - Create .env file
# Hostname of the back-end server (default: localhost)
BACKEND_HOSTNAME=localhost
# Port of the back-end server (default: 5000)
BACKEND_PORT=5000
# Secret key for front-end application
SECRET_KEY=your_secret_key_here
# Port where the front-end server will run (default: 8000)
SERVER_PORT=8000- Run app by following command:
python3 app.pyRequired is postgresql. Either run given docker-compose.yaml file or provide setup for backend's .env file
services:
postgres:
image: postgres
environment:
POSTGRES_PASSWORD: alamakota
POSTGRES_USER: board_games
POSTGRES_DB: games
ports:
- 5432:5432Deploy helm chart:
cd charts
helm install app .Check if pods are working:
kubectl get podsOutput should be similiar to:
NAME READY STATUS RESTARTS AGE
app-backend-6f8d54dd7f-jmrkl 1/1 Running 0 20m
app-frontend-8657bb558b-dfr4d 1/1 Running 0 20m