Skip to content

This repository contains the API endpoints of Airtech Services. This enables users to be authenticated and authorized before booking a flight ticket, purchase tickets, make flight reservations amongst others. This project is built using Django rest framework.

License

Notifications You must be signed in to change notification settings

Celoka/flight-booking-system

Repository files navigation

Build Status Coverage Status

Flight Booking System

This repository contains the API endpoints of Airtech Services. This enables users to be authenticated and authorized before booking a flight ticket, purchase tickets, make flight reservations amongst others. This project is built using Django rest framework.

The url to the API could be found here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

  • Install pip if it is not installed yet in your system

  • To install virtual environment, run in your terminal:

pip install virtualenv
  • To create a virtual environment, in the root folder of the cloned app, run:
virtualenv -p python3 venv
  • To activate the virtualenv:
source venv/bin/activate
  • Run the command below to install all the project dependencies:
pip install -r requirements.txt
  • To deactivate the virtualenv:
deactivate

Installing

  • Clone this repository

https://github.com/Celoka/flight-booking-system.git

  • Cd into the cloned app, create a virtualenv and activate(see instruction above for steps to create a virtualenv)

  • Create a .env file, copy the variables in the .env_sample in the root directory of the project and set up the configurations according to your system.

  • Ensure to makemigrations then migrate by running the following commands sequencially:

- python manage.py makemigrations

- python manage.py migrate
  • To start the application, in the root directory of the project, run:
python manage.py runserver
  • Run the below command to start Celery worker and Celery beat:
celery -A flight_booking_api worker --loglevel=info

celery -A flight_booking_api beat --loglevel=info
  • To start up the RabbitMQ server:
rabbitmq-server

Running the tests

  • To run test:
python manage.py test
  • Test coverage:
coverage run manage.py test
  • Coverage report:
coverage report

Features of the Project

  • Registration
  • Login
  • Upload Passport Photo
  • Admin Create Flight
  • Book Tickets
  • Purchase Tickets
  • Receive Tickets as Email
  • Make Flight Reservation
  • Check Flight Status

API Documentation

  • The API is documented with Postman. See the API Doc for details.

Built With

  • Python 3
  • Postgresql
  • Django Rest Framework (API development)
  • Celery (Asynchronous Task Queue)
  • RabbitMQ (A message broker)
  • Insomnia (API Test tool)

Authors

  • Eloka Chima

License

  • This project is licensed under the MIT License - see the LICENCE file for details

About

This repository contains the API endpoints of Airtech Services. This enables users to be authenticated and authorized before booking a flight ticket, purchase tickets, make flight reservations amongst others. This project is built using Django rest framework.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published