Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/atharv-naik/smc-mess-backend

A canteen mess management system API in Django
https://github.com/atharv-naik/smc-mess-backend

django django-rest-framework

Last synced: about 1 month ago
JSON representation

A canteen mess management system API in Django

Awesome Lists containing this project

README

        

# smc-mess-backend

This is the backend for the SMC Mess application. It is a REST API written in Python using the Django framework. The project is part of the 2023 summer internship at IISER Kolkata.

## Installation

1. Clone the repository

2. Create a virtual environment and activate it

3. Create a `.env` file in the project base directory and add the following

```bash
EMAIL_ID =
GOOGLE_APP_PASSWORD =
```

4. Install the dependencies

```bash
pip install -r requirements.txt
```

5. Install celery and redis-server

```bash
sudo apt install celery redis-server
```

6. Make migrations

```bash
python manage.py makemigrations
python manage.py migrate
```

7. Create a superuser

```bash
python manage.py createsuperuser
```

8. Populate the database with fake data

```bash
python populate_db.py
```

9. Run the server

```bash
python manage.py runserver
```

10. In a seperate terminal, run the celery worker

```bash
celery -A MessSystemSMC worker -l info
```

11. Go to `http://localhost:8000/api` for a summery of all the api endpoints exposed