Skip to content

fedyhajali/ticketing-system

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ticketing-system

This is an example of Ticketing Management System realized for the "Application Distribuited and Mobile course" course at the University of Modena and Reggio Emilia.

Ticket Lifecycle

Ticket Management

Getting Started

Installation

Clone Project from repo access to directory

git clone https://github.com/FedyHajali/ticketing-system.git
cd /.../path-to/ticketing-system

There are two options for starting the project:

1. Run with Docker

Build Docker containers

sudo docker-compose build

Start containers in detached mode

sudo docker-compose up -d

First setup

If it's your first time running the project, perform the initial configuration below.

Make PostgreSQL migrations and create you first user as administrator of the system.

sudo docker-compose exec api python3 manage.py makemigrations
sudo docker-compose exec api python3 manage.py migrate
sudo docker exec -it api python3 manage.py createsuperuser

# docker-compose exec [docker-service] python3 manage.py [command]

Browse http://localhost:4200/

Stop Containers

Stops and removes containers, networks, volumes, and images created by 'up' command.

sudo docker-compose down

2. Run Local

Backend setup

Setup virtual environment

cd backend
python -m venv .venv
source activate .venv

Install requirements

pip install -r requirements.txt

First Setup - Django

Make PostgreSQL migrations and create you first user as administrator of the system.

python manage.py makemigrations
python manage.py migrate
python manage.py createsuperuser

Launch Django Backend

python manage.py runserver

Celery setup

Start redis (from /backend/redis folder):

.\redis-server.exe

Start beat celery scheduler:

celery -A services beat -l INFO

Start celery worker:

celery -A services worker --pool=solo -l info

Frontend setup

cd frontend

Installation of packages:

npm install

Generate new API:

npm run generate-api

Run UI module:

npm start

Browse http://localhost:4200/

Authors

Fedy Haj Ali, Giacomo Capitani