File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 33from .base import * # noqa
44
55EMAIL_BACKEND = "django.core.mail.backends.smtp.EmailBackend"
6- EMAIL_HOST = "' smtp.google .com' "
6+ EMAIL_HOST = "smtp.gmail .com"
77EMAIL_PORT = 587
88EMAIL_HOST_USER = os .getenv ("EMAIL_HOST_USER" )
99EMAIL_HOST_PASSWORD = os .getenv ("EMAIL_HOST_PASSWORD" )
1010EMAIL_USE_TLS = True
1111
12- DATABASES_ENVIRON = os .getenv ("DATABASE_ENVIRON" )
12+ DATABASE_ENVIRON = os .getenv ("DATABASE_ENVIRON" )
1313
14- if DATABASES_ENVIRON == "postgresql" :
14+ if DATABASE_ENVIRON == "postgresql" :
1515 DATABASES = {
1616 "default" : {
1717 "ENGINE" : f"django.db.backends.postgresql" ,
2222 "PORT" : int (os .getenv ("DATABASE_PORT" ))
2323 }
2424 }
25- elif DATABASES_ENVIRON == 'mysql' :
25+ elif DATABASE_ENVIRON == 'mysql' :
2626 DATABASES = {
2727 "default" : {
2828 "ENGINE" : f"django.db.backends.mysql" ,
3636 }
3737 }
3838 }
39+ else :
40+ raise ValueError ("DATABASES_ENVIRON is not set correctly. Please set it to 'postgresql' or 'mysql'. " )
You can’t perform that action at this time.
0 commit comments