feat: 视频与控制程序合并
This commit is contained in:
@@ -1,7 +1,13 @@
|
||||
import os
|
||||
from pathlib import Path
|
||||
|
||||
BASE_DIR = Path(__file__).resolve().parent.parent
|
||||
|
||||
|
||||
def _split_csv_env(name: str) -> list[str]:
|
||||
value = os.getenv(name, "")
|
||||
return [item.strip().rstrip("/") for item in value.split(",") if item.strip()]
|
||||
|
||||
SECRET_KEY = 'django-insecure-pk4scm@ifo%mao6l=j0@-$_v+pg-43^hj4a!199^)zivz-_8xu'
|
||||
DEBUG = True
|
||||
ALLOWED_HOSTS = ["*"]
|
||||
@@ -87,3 +93,16 @@ STATIC_URL = 'static/'
|
||||
CORS_ALLOW_ALL_ORIGINS = True
|
||||
|
||||
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
|
||||
|
||||
CONTROL_WS_ALLOWED_ORIGINS = _split_csv_env('CONTROL_WS_ALLOWED_ORIGINS') or [
|
||||
'http://127.0.0.1',
|
||||
'http://127.0.0.1:5173',
|
||||
'http://127.0.0.1:4173',
|
||||
'http://127.0.0.1:8001',
|
||||
'https://127.0.0.1',
|
||||
'http://localhost:5173',
|
||||
'http://localhost:4173',
|
||||
'http://localhost',
|
||||
'http://localhost:8001',
|
||||
'https://localhost',
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user