1.9 KiB
1.9 KiB
repo, branch, commit, doc_type
| repo | branch | commit | doc_type |
|---|---|---|---|
| rabbitta/rabitta.ru | main | d1ac46c45a |
technical |
Technical documentation for Rabitta
Overview
Rabitta is a web-based application designed to manage rabbit populations. It provides features such as tracking rabbit health, feeding schedules, and breeding records. The application is built using Python with the Django framework and PostgreSQL as the database.
Repository Structure
The Rabitta repository follows a standard Django project structure:
rabbitta/manage.py- The main entry point for Django's administrative tasks.rabbitta/settings.py- Configuration settings for the Django application.rabbitta/urls.py- URL routing configuration.rabbitta/wsgi.py- WSGI configuration for deploying the application.
Dependencies
The Rabitta repository depends on the following Python packages:
- Django (version 3.2)
- PostgreSQL (version 12 or higher)
- psycopg2 (PostgreSQL adapter for Python)
- djangorestframework (for API development)
- gunicorn (web server gateway interface)
Database Setup
To set up the database, follow these steps:
- Install PostgreSQL and create a new database named
rabbitta. - Update the
DATABASESsetting inrabbitta/settings.pyto connect to your PostgreSQL instance.
Running the Application
To run the Rabitta application, use the following commands:
python manage.py makemigrations
python manage.py migrate
python manage.py createsuperuser
python manage.py runserver
This will start the Django development server at http://127.0.0.1:8000/.
API Endpoints
The Rabitta application provides the following RESTful API endpoints:
GET /api/rabbits/- Retrieve a list of all rabbits.POST /api/rabbits/- Create a new rabbit.PUT /api/rabbits/{id}/- Update an existing rabbit.DELETE /api/rabbits/{id}/- Delete a rabbit.
License
Rabitta is licensed under the MIT license.