Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file removed backend/api/migrations/__init__.py
Empty file.
71 changes: 0 additions & 71 deletions backend/categories/migrations/0001_initial.py

This file was deleted.

Empty file.
9 changes: 9 additions & 0 deletions backend/forecast/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
'rest_framework.authtoken',
'djoser',
'drf_yasg',
'corsheaders',
'api.apps.ApiConfig',
'categories.apps.CategoriesConfig',
'sales_forecasts.apps.SalesForecastsConfig',
Expand All @@ -43,6 +44,8 @@
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'corsheaders.middleware.CorsMiddleware',
'django.middleware.common.CommonMiddleware',
]

ROOT_URLCONF = 'forecast.urls'
Expand Down Expand Up @@ -144,3 +147,9 @@
MEDIA_ROOT = '/media'

DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'


CORS_ORIGIN_WHITELIST = [
'http://localhost:8000',
'http://127.0.0.1:8000',
]
4 changes: 3 additions & 1 deletion backend/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ cryptography==41.0.4
defusedxml==0.7.1
Django==4.2.5
django-bulk-update==2.2.0
django-cors-headers==4.2.0
django-filter==23.3
django-templated-mail==1.1.1
djangorestframework==3.14.0
Expand All @@ -26,4 +27,5 @@ social-auth-core==4.4.2
sqlparse==0.4.4
tzdata==2023.3
urllib3==2.0.5
drf-yasg==1.21.7
drf-yasg==1.21.7
gunicorn==21.2.0
35 changes: 0 additions & 35 deletions backend/sales/migrations/0001_initial.py

This file was deleted.

Empty file.
54 changes: 0 additions & 54 deletions backend/sales_forecasts/migrations/0001_initial.py

This file was deleted.

This file was deleted.

Empty file.
57 changes: 0 additions & 57 deletions backend/stores/migrations/0001_initial.py

This file was deleted.

Empty file.
Empty file.
2 changes: 1 addition & 1 deletion gateway/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
FROM nginx:1.22.1
COPY nginx.conf /etc/nginx/templates/default.conf.template
COPY nginx.conf /etc/nginx/templates/default.conf.template
6 changes: 6 additions & 0 deletions gateway/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,17 @@ server {
proxy_set_header Host $http_host;
proxy_pass http://backend:8000/api/v1/;
}

location /admin/ {
proxy_set_header Host $http_host;
proxy_pass http://backend:8000/admin/;
}

location /swagger/ {
proxy_set_header Host $http_host;
proxy_pass http://backend:8000/swagger/;
}

location /media/ {
proxy_set_header Host $http_host;
alias /media/;
Expand Down