Reservation management system for the ASBL Village des Benjamins.
- Backend: Django 6.0 with Django REST Framework
- Database: PostgreSQL
- Frontend: Vue.js
- Package Manager: uv (Python), npm (JavaScript)
- Development Environment: Nix with devenv
- Email: SendGrid (production), Mailpit (development)
- Storage: AWS S3 (production), MinIO (development)
-
Enter the development environment:
# If using direnv (recommended) direnv allow # Or manually enter the nix shell nix develop
This automatically sets up:
- Python 3.13 with uv
- Node.js with npm
- PostgreSQL (database:
vdb, user:vdb) - MinIO (S3-compatible storage on port 9000)
- Mailpit (email testing on ports 1025/8025)
- All necessary environment variables
-
Start background services:
devenv up
This starts PostgreSQL, MinIO, and Mailpit in the background.
-
Run database migrations (in a new terminal):
python manage.py migrate
-
Create a superuser:
python manage.py createsuperuser
-
Run the development server:
python manage.py runserver
-
Access the application:
- Frontend: http://localhost:8000
- Admin panel: http://localhost:8000/admin
- Mailpit (emails): http://localhost:8025
- MinIO console: http://localhost:9001 (minioadmin/minioadmin)
- Automatically started by devenv
- Database:
vdb - User:
vdb(superuser) - Connection via Unix socket
All emails sent during local development are captured by Mailpit.
- Web interface: http://localhost:8025
- SMTP port: 1025
- View all sent emails without actually sending them
Local S3-compatible object storage for file uploads.
- Console: http://localhost:9001
- API: http://localhost:9000
- Credentials: minioadmin/minioadmin
- Bucket:
village-des-benjamins(auto-created)
# Install new Python package
uv add <package-name>
# Install dev dependency
uv add --dev <package-name>
# Run Django management command
python manage.py <command>
# Run tests
python manage.py test
# Format code
treefmt
# Start all background services
devenv up
# Stop all services
# Press Ctrl+C in the devenv up terminal
# Update flake dependencies
nix flake updatevillage_des_benjamins/
├── frontend/ # Vue.js frontend
├── holiday/ # Holiday/vacation management
├── members/ # User and child management
├── parent_messages/ # Parent communication
├── section/ # Section/group management
├── site_content/ # CMS content
├── village_des_benjamins/ # Django project settings
├── flake.nix # Nix flake with devenv config
├── pyproject.toml # Python dependencies (uv)
└── manage.py # Django management script
All development environment variables are configured in flake.nix under the env section. You can override them by creating a .env file in the project root.
Key variables:
DATABASE_URL- PostgreSQL connection (auto-configured)DEBUG- Django debug mode (true in dev)EMAIL_HOST/EMAIL_PORT- Mailpit configurationAWS_S3_ENDPOINT_URL- MinIO endpointAWS_STORAGE_BUCKET_NAME- S3 bucket name
Production uses:
- PostgreSQL database
- SendGrid for email delivery
- AWS S3 for file storage
- GlitchTip for error tracking
Required environment variables:
SECRET_KEYDATABASE_URLSENDGRID_API_KEYMAIL_FROM_ADDRESSAWS_ACCESS_KEY_IDAWS_SECRET_ACCESS_KEYAWS_STORAGE_BUCKET_NAMESENTRY_DSNDEBUG=falseSSL=true
This project uses devenv for reproducible development environments. The configuration in flake.nix includes:
- Python environment with Poetry/uv
- Node.js environment with npm
- PostgreSQL database service
- MinIO S3-compatible storage
- Mailpit email testing server
- Pre-commit hooks for code quality
- Code formatters (black, prettier, etc.)
To update the development environment configuration, edit flake.nix and run:
nix flake lock --update-input devenv