feat: Add comprehensive Django user app with tests using model-bakery
- Implemented user authentication with JWT tokens - Added user and profile models with OneToOne relationship - Created service layer for business logic separation - Implemented DRF serializers and views - Added comprehensive test suite with model-bakery factories - Fixed ipdb/pdbpp dependency conflicts with custom test runner - Configured development and production environments - Added deployment configurations for Apache, systemd, and Docker
This commit is contained in:
27
deploy/systemd/gunicorn.service
Normal file
27
deploy/systemd/gunicorn.service
Normal file
@@ -0,0 +1,27 @@
|
||||
[Unit]
|
||||
Description=Gunicorn daemon for Django project
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
User=www-data
|
||||
Group=www-data
|
||||
RuntimeDirectory=gunicorn
|
||||
WorkingDirectory=/var/www/project/src
|
||||
ExecStart=/var/www/project/venv/bin/gunicorn config.wsgi:application \
|
||||
--bind unix:/run/gunicorn.sock \
|
||||
--workers 3 \
|
||||
--worker-class gevent \
|
||||
--worker-connections 1000 \
|
||||
--timeout 30 \
|
||||
--keep-alive 2 \
|
||||
--max-requests 1000 \
|
||||
--max-requests-jitter 100 \
|
||||
--preload
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
KillMode=mixed
|
||||
TimeoutStopSec=5
|
||||
PrivateTmp=true
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user