浏览代码

set MEDIA_ROOT

ignatz 4 年之前
父节点
当前提交
880362bb67
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      st_cloud/settings.py

+ 1 - 0
st_cloud/settings.py

@@ -14,6 +14,7 @@ from pathlib import Path
 
 
 # Build paths inside the project like this: BASE_DIR / 'subdir'.
 # Build paths inside the project like this: BASE_DIR / 'subdir'.
 BASE_DIR = Path(__file__).resolve().parent.parent
 BASE_DIR = Path(__file__).resolve().parent.parent
+MEDIA_ROOT = BASE_DIR / 'upload/'
 
 
 # Quick-start development settings - unsuitable for production
 # Quick-start development settings - unsuitable for production
 # See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/
 # See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/