feat: 웹사이트 표준화 검사 도구 구현
- 4개 검사 엔진: HTML/CSS, 접근성(WCAG), SEO, 성능/보안 (총 50개 항목) - FastAPI 백엔드 (9개 API, SSE 실시간 진행, PDF/JSON 리포트) - Next.js 15 프론트엔드 (6개 페이지, 29개 컴포넌트, 반원 게이지 차트) - Docker Compose 배포 (Backend:8011, Frontend:3011, MongoDB:27022, Redis:6392) - 전체 테스트 32/32 PASS Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
34
backend/app/core/config.py
Normal file
34
backend/app/core/config.py
Normal file
@ -0,0 +1,34 @@
|
||||
"""
|
||||
Application configuration from environment variables.
|
||||
"""
|
||||
|
||||
from pydantic_settings import BaseSettings
|
||||
from functools import lru_cache
|
||||
|
||||
|
||||
class Settings(BaseSettings):
|
||||
"""Application settings loaded from environment variables."""
|
||||
|
||||
# MongoDB
|
||||
MONGODB_URL: str = "mongodb://admin:password123@localhost:27022/"
|
||||
DB_NAME: str = "web_inspector"
|
||||
|
||||
# Redis
|
||||
REDIS_URL: str = "redis://localhost:6392"
|
||||
|
||||
# Inspection
|
||||
URL_FETCH_TIMEOUT: int = 10
|
||||
CATEGORY_TIMEOUT: int = 60
|
||||
MAX_HTML_SIZE: int = 10485760 # 10MB
|
||||
|
||||
# Application
|
||||
PROJECT_NAME: str = "Web Inspector API"
|
||||
|
||||
class Config:
|
||||
env_file = ".env"
|
||||
case_sensitive = True
|
||||
|
||||
|
||||
@lru_cache()
|
||||
def get_settings() -> Settings:
|
||||
return Settings()
|
||||
Reference in New Issue
Block a user