Django on Windows Development Tips - JRK Labs

Django on Windows Development Tips

Feb. 18, 2024

Tips and tricks gathered during development of Django and Wagtail web applications on a Windows 11 operating system.
Set Environment variables in Powershell

Configuring a sqlite DATABASE_URL in the root of the current project.

$env:DATABASE_URL = 'sqlite:///db.sqlite3'

A few other examples:

$env:USE_DOCKER = 'No' $Env:DJANGO_DEBUG = 'True'
Python Tips

Use the --settings flag on commands to indicate a different settings configuration file is to be used.

python .\ runserver --settings config.settings.local

Return to blog

JRK Labs LLC 570.594.4964 hello AT