django-prod
Quickly deploy over SSH your newly generated django project.
This package provides two management commands:
django_prod_init— generates all production files you need.django_prod_deploy— deploys your project to a remote SERVER over SSH.
📦 Installation
Install the package:
pip install django-prod
🛠 Example
Create a new django project:
django-admin startproject webapp .
Add django-prod to installed apps:
# settings.py
INSTALLED_APPS = [
...
"django_prod",
]
Initialize production files:
python manage.py django_prod_init
Deploy to your server:
python manage.py django_prod_deploy
You will be prompted for:
- Server IP address
- SSH username
- Path to your SSH private key
Then the script will:
- Upload your project to the server
- Ensure Docker is installed
- Run your production stack with Docker Compose
This project is opinionated and uses the simplest technologies possible to move from development to production quickly. It relies on SQLite as the production database, and for those who still consider SQLite a “toy database,” I strongly encourage you to look into its performance when properly configured. That’s why the project includes a dedicated configuration to get the most out of SQLite (see settings_prod.py).
It also uses WhiteNoise to handle static files. Performance is more than acceptable once assets are cached and served through a CDN (for example, a Cloudflare proxy).
The third technology used is Docker and Docker Compose. no need to explain why :)
Release files for django-prod 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| django_prod-0.1.3.tar.gz | 79.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| django_prod-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 96.1 kB
Release files / django_prod-0.1.3.tar.gz
| Download URL | django_prod-0.1.3.tar.gz |
|---|---|
| Size | 79.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1c9e3d0e1ca3551ad6fcba07ad8d46f1bde3cad934d76fe1d72f65fa724ab067
|
|
BLAKE2b-256 checksum How to use checksums |
41da28f2b2895635fff5d2e21fd342bdcaf5de43930dee421cc80a12d582239a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.3
|
Release files / django_prod-0.1.3-py3-none-any.whl
| Download URL | django_prod-0.1.3-py3-none-any.whl |
|---|---|
| Size | 16.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
522a04ee0756e8a29745e94d3c223880189f6e370d05988a12b27f5cc45a5eac
|
|
BLAKE2b-256 checksum How to use checksums |
a31ec830517401701035b5e7deebc287600754c8e9dc01a745bfb8dc297826bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.3
|