Update the database to use Postgres.

This commit is contained in:
2023-07-24 13:24:35 +03:00
parent b1e9c7e713
commit bc585a1c60
4 changed files with 19 additions and 2 deletions
+7
View File
@@ -1,2 +1,9 @@
DEBUG=True
SECRET_KEY='your-secure-key'
DATABASE_NAME=postgres_dev
DATABASE_USERNAME=postgres
DATABASE_PASSWORD=testpassword
DATABASE_HOST=postgres
DATABASE_PORT=5432
+2
View File
@@ -30,4 +30,6 @@
Add the tests for circular next methods.
** 0.3.7 <2023-07-23 Sun>
Add the action to set the circular next status for Task items.
** 0.3.8 <2023-07-24 Mon>
Update the database to use Postgres.
+4
View File
@@ -1,8 +1,12 @@
asgiref==3.7.2
crispy-tailwind==0.5.0
Django==4.2.3
django-browser-reload==1.11.0
django-crispy-forms==2.0
django-tailwind==3.6.0
gunicorn==21.2.0
packaging==23.1
psycopg2-binary==2.9.6
python-dotenv==1.0.0
sqlparse==0.4.4
typing_extensions==4.7.1
+6 -2
View File
@@ -75,8 +75,12 @@ WSGI_APPLICATION = "simple_todo_list.wsgi.application"
DATABASES = {
"default": {
"ENGINE": "django.db.backends.sqlite3",
"NAME": BASE_DIR / "db.sqlite3",
"ENGINE": "django.db.backends.postgresql",
'NAME': os.environ.get('DATABASE_NAME'),
'USER': os.environ.get('DATABASE_USERNAME'),
'PASSWORD': os.environ.get('DATABASE_PASSWORD'),
'HOST': os.environ.get('DATABASE_HOST'),
'PORT': os.environ.get('DATABASE_PORT'),
}
}