Python 3
uv sync --frozen && uv cache prune --ci && uv run manage.py makemigrations && uv run manage.py migrate
uv run manage.py runserver 0.0.0.0:$PORT
(this is a dev server, for prod deployments use gunicorn
)Free
For Django:
ALLOWED_HOSTS
, value: *
CSRF_TRUSTED_ORIGINS
: https://*.onrender.com
.env.local
.env
:
ALLOWED_HOSTS=*
CSRF_TRUSTED_ORIGINS=https://*.onrender.com
uv add psycopg2-binary &&
to build command:
uv add psycopg2-binary && uv sync --frozen && uv cache prune --ci && uv run manage.py migrate