Skip to content

Commit 8801ed5

Browse files
authored
Merge pull request #3 from golony6449/feature/drf
Django Rest Framework 의존성 추가
2 parents de1f199 + adb712e commit 8801ed5

File tree

4 files changed

+20
-1
lines changed

4 files changed

+20
-1
lines changed

pyconkr/settings-dev.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import os
2+
3+
DEBUG = True
4+
5+
# RDS
6+
DATABASES = {
7+
"default": {
8+
"ENGINE": "mysql.connector.django",
9+
"NAME": os.getenv("AWS_RDS_DATABASE"),
10+
"USER": os.getenv("AWS_RDS_USER_ID"),
11+
"PASSWORD": os.getenv("AWS_RDS_PW"),
12+
"HOST": os.getenv("AWS_RDS_HOST"),
13+
"PORT": os.getenv("AWS_RDS_PORT"),
14+
}
15+
}

pyconkr/settings.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@
3737
"django.contrib.sessions",
3838
"django.contrib.messages",
3939
"django.contrib.staticfiles",
40+
41+
# djangorestframework
42+
"rest_framework",
4043
]
4144

4245
MIDDLEWARE = [

pyconkr/urls.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@
1414
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
1515
"""
1616
from django.contrib import admin
17-
from django.urls import path
17+
from django.urls import path, include
1818

1919
urlpatterns = [
20+
path('api-auth/', include('rest_framework.urls')),
2021
path("admin/", admin.site.urls),
2122
]

requirements.txt

150 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)