Welcome to the Airport Service API! This API has been designed to track flights from airports on local, regional and global scales.
- JWT authentication
- Admin panel /admin/
- Managing orders and tickets
- Creating routes (based on airports)
- Creating airplanes and airlines
- Creating crews
- Creating flights as complex objects
- Filtering routes by different variations of country and city
- Filtering flights by source, destination and date of the departure
- The ability to upload images to airplanes
Clone this repository:
git clone https://github.com/callogan/airport-service-api
cd airport-service-api-
The main branch is considered as the most sustainable branch, therefore it is recommended to work from it.
-
If you intend to run the application locally, follow the next steps:
-
Create the virtual environment:
python -m venv venv
-
Activate the virtual environment:
On Windows:
venv\Scripts\activate
On macOS and Linux:
source venv/bin/activate -
Install dependencies:
pip install -r requirements.txt
-
Copy this file ".env.sample" and rename it to ".env", then fill in the actual values for your local environment.
-
Apply the migrations:
python manage.py migrate
-
In order to run the development server, use the following command:
python manage.py runserver
- You might as well run the application via the Docker. For this purpose make certain the Docker is installed on your computer and follow the next steps:
- Fill the actual data for ".env" file (as was mentioned above).
- Build the Docker image and start the containers for the application and the database:
docker-compose up --build
Access the application in your web browser at http://localhost:8000.
-
This project includes the fixture that is used for demonstration purpose. The fixture contains basic dataset representing various project entities.
-
The fixture named
airport_service_db_data.jsonis located in the root directory. -
In order to load the fixture data into the application, use the following command:
python manage.py loaddata data_for_db.json
- Django REST Framework This is toolbox for designing Web APIs, providing features such as serialization, authentication, API views and viewsets to streamline the development of RESTful services in Django applications.
- Docker This is open source containerization platform that enables developers to package applications into containers, simplifying the process of building, running, managing and distributing applications throughout different execution environments.
- PostgreSQL This is a powerful, open source object-relational database management system.
- Swagger This is open source suite of tools to generate API documentation.
Authentication of users is incorporated with means of JSON Web Tokens.
Copyright (c) 2024 Ruslan Kazmiryk


