#!/usr/bin/env python3
"""
Vultr MCP Server - Main Entry Point
"""
import logging
import uvicorn
from src.vultr_mcp.server import mcp, config

# Load environment variables are now handled by config loader

logging.basicConfig(level=config.get('server', {}).get('log_level', 'info').upper())
logger = logging.getLogger(__name__)

if __name__ == "__main__":
    server_config = config.get('server', {})
    host = server_config.get('host', '127.0.0.1')
    port = server_config.get('port', 8000)
    
    logger.info(f"Starting Vultr MCP Server on {host}:{port}...")
    
    # Use uvicorn to run the FastAPI app (mcp is a FastAPI app)
    uvicorn.run(mcp, host=host, port=port)
