|
@@ -14,8 +14,8 @@ class Settings(BaseSettings):
|
|
# BACKEND_CORS_ORIGINS is a JSON-formatted list of origins
|
|
# BACKEND_CORS_ORIGINS is a JSON-formatted list of origins
|
|
# e.g: '["http://localhost", "http://localhost:4200", "http://localhost:3000", \
|
|
# e.g: '["http://localhost", "http://localhost:4200", "http://localhost:3000", \
|
|
# "http://localhost:8080", "http://local.dockertoolbox.tiangolo.com"]'
|
|
# "http://localhost:8080", "http://local.dockertoolbox.tiangolo.com"]'
|
|
- BACKEND_CORS_ORIGINS: List[AnyHttpUrl] = ["*"]
|
|
|
|
- '''
|
|
|
|
|
|
+ BACKEND_CORS_ORIGINS: List[AnyHttpUrl] = []
|
|
|
|
+
|
|
@validator("BACKEND_CORS_ORIGINS", pre=True)
|
|
@validator("BACKEND_CORS_ORIGINS", pre=True)
|
|
def assemble_cors_origins(cls, v: Union[str, List[str]]) -> Union[List[str], str]:
|
|
def assemble_cors_origins(cls, v: Union[str, List[str]]) -> Union[List[str], str]:
|
|
if isinstance(v, str) and not v.startswith("["):
|
|
if isinstance(v, str) and not v.startswith("["):
|
|
@@ -23,7 +23,7 @@ class Settings(BaseSettings):
|
|
elif isinstance(v, (list, str)):
|
|
elif isinstance(v, (list, str)):
|
|
return v
|
|
return v
|
|
raise ValueError(v)
|
|
raise ValueError(v)
|
|
- '''
|
|
|
|
|
|
+
|
|
PROJECT_NAME: str = "ai-anchor"
|
|
PROJECT_NAME: str = "ai-anchor"
|
|
SENTRY_DSN: Optional[HttpUrl] = None
|
|
SENTRY_DSN: Optional[HttpUrl] = None
|
|
|
|
|