Skip to content

Commit e54bead

Browse files
committed
feat(settings): use DJANGO_DB_DIR in database config
1 parent a203f0b commit e54bead

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

benefits/settings.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Django settings for benefits project.
33
"""
44
import os
5+
56
from benefits import sentry
67

78

@@ -147,10 +148,11 @@ def _filter_empty(ls):
147148

148149
WSGI_APPLICATION = "benefits.wsgi.application"
149150

151+
DATABASE_DIR = os.environ.get("DJANGO_DB_DIR", BASE_DIR)
150152
DATABASES = {
151153
"default": {
152154
"ENGINE": "django.db.backends.sqlite3",
153-
"NAME": "django.db",
155+
"NAME": os.path.join(DATABASE_DIR, "django.db"),
154156
}
155157
}
156158

0 commit comments

Comments
 (0)