# FastAPI Application Configuration
# This is a sample environment file. Copy to .env and update the values as needed

# Backend Configuration
BACKEND_PORT=8000
BACKEND_HOST=0.0.0.0
DEBUG=True
ENVIRONMENT=development

# Database Configuration
# Primary database URL (used by both FastAPI and Alembic)
DATABASE_URL=sqlite:///./{{ project_name }}.db

# MongoDB
MONGODB_URI=mongodb://localhost:27017/{{ project_name }}
MONGODB_DATABASE={{ project_name }}

# PostgreSQL
POSTGRES_HOST=localhost
POSTGRES_PORT=5432
POSTGRES_DATABASE={{ project_name }}
POSTGRES_USER=postgres
POSTGRES_PASSWORD=password
POSTGRES_URI=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DATABASE}

# MySQL
MYSQL_HOST=localhost
MYSQL_PORT=3306
MYSQL_DATABASE={{ project_name }}
MYSQL_USER=root
MYSQL_PASSWORD=password
MYSQL_URI=mysql://${MYSQL_USER}:${MYSQL_PASSWORD}@${MYSQL_HOST}:${MYSQL_PORT}/${MYSQL_DATABASE}

# SQLite
SQLITE_DATABASE=./{{ project_name }}.db

# Alembic Configuration
# Uncomment and update these if you want to override alembic.ini settings
# ALEMBIC_SCRIPT_LOCATION=alembic
# ALEMBIC_SQLALCHEMY_URL=${DATABASE_URL}

# Redis Configuration
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_DB=0
REDIS_PASSWORD=
REDIS_URI=redis://${REDIS_PASSWORD}@${REDIS_HOST}:${REDIS_PORT}/${REDIS_DB}

# Celery Configuration
CELERY_BROKER_URL=redis://${REDIS_HOST}:${REDIS_PORT}/${REDIS_DB}
CELERY_RESULT_BACKEND=redis://${REDIS_HOST}:${REDIS_PORT}/${REDIS_DB}
CELERY_TASK_SERIALIZER=json
CELERY_RESULT_SERIALIZER=json
CELERY_ACCEPT_CONTENT=json
CELERY_TIMEZONE=UTC

# JWT Configuration
JWT_SECRET_KEY=your-secret-key-here
JWT_ALGORITHM=HS256
JWT_ACCESS_TOKEN_EXPIRE_MINUTES=30

# CORS Configuration
CORS_ORIGINS=["http://localhost:3000", "http://localhost:8080"]

# Logging Configuration
LOG_LEVEL=INFO
LOG_FORMAT=%(asctime)s - %(name)s - %(levelname)s - %(message)s

# API Configuration
API_V1_PREFIX=/api/v1
PROJECT_NAME={{ project_name }}
PROJECT_VERSION=0.1.0
PROJECT_DESCRIPTION="A FastAPI project generated with FasCraft"
