diff --git a/Backend/backend/backend/settings.py b/Backend/backend/backend/settings.py index e8d68e9e..a5dfd432 100644 --- a/Backend/backend/backend/settings.py +++ b/Backend/backend/backend/settings.py @@ -151,7 +151,7 @@ os.path.join(BASE_DIR, "static") ] -MEDIA_URL = '/media/' +MEDIA_URL = '/code/media/' MEDIA_ROOT = os.path.join(BASE_DIR, 'media') # Default primary key field type # https://docs.djangoproject.com/en/4.2/ref/settings/#default-auto-field @@ -161,18 +161,15 @@ CORS_ALLOWED_ORIGINS = [ "http://mac-server:5000", - "http://mac-server:8080", "http://localhost:5000", - "http://localhost:8080", - "http://frontend:8080", + "https://foodplaner-demo.robin-stark.com" + ] CSRF_TRUSTED_ORIGINS = [ "http://mac-server:5000", - "http://mac-server:8080", "http://localhost:5000", - "http://localhost:8080", - "http://frontend:8080", + "https://foodplaner-demo.robin-stark.com" ] CORS_ALLOW_CREDENTIALS = True diff --git a/docker-compose.yml b/docker-compose.yml index 70c6e1f7..b36b88bf 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -13,7 +13,7 @@ services: backend: build: context: ./Backend/backend - command: gunicorn backend.wsgi:application --bind 0.0.0.0:8000 + command: gunicorn backend.wsgi:application --bind 0.0.0.0:8000 --workers 17 --timeout 30 volumes: - .:/code - ./data/media:/code/media