diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c04c1f9 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,21 @@ +# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile +# Use a base Python image +FROM python:3.9-slim + +# Set the working directory +WORKDIR /app + +# Copy the current directory contents into the container at /app +ADD . /app + +# Install the required Python packages +RUN pip install --no-cache-dir -r requirements.txt + +# Set environment variable for the database path +ENV SQLITE_DB_PATH="/path/to/your/database.db" + +# Expose the port the app runs on +EXPOSE 8000 + +# Run the server +CMD ["uvicorn", "sqlite_explorer:app", "--host", "0.0.0.0", "--port", "8000"] \ No newline at end of file diff --git a/README.md b/README.md index f6ee347..37025b2 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # SQLite Explorer MCP Server +[![smithery badge](https://smithery.ai/badge/@hannesrudolph/sqlite-explorer-fastmcp-mcp-server)](https://smithery.ai/server/@hannesrudolph/sqlite-explorer-fastmcp-mcp-server) + An MCP server that provides safe, read-only access to SQLite databases through Model Context Protocol (MCP). This server is built with the FastMCP framework, which enables LLMs to explore and query SQLite databases with built-in safety features and query validation. ## 📋 System Requirements @@ -69,6 +71,14 @@ You can install this MCP server in either Claude Desktop or the Cline VSCode plu ### Option 1: Install for Claude Desktop +#### Installing via Smithery + +To install SQLite Explorer for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@hannesrudolph/sqlite-explorer-fastmcp-mcp-server): + +```bash +npx -y @smithery/cli install @hannesrudolph/sqlite-explorer-fastmcp-mcp-server --client claude +``` + Install using FastMCP: ```bash diff --git a/smithery.yaml b/smithery.yaml new file mode 100644 index 0000000..2b80094 --- /dev/null +++ b/smithery.yaml @@ -0,0 +1,17 @@ +# Smithery configuration file: https://smithery.ai/docs/config#smitheryyaml + +startCommand: + type: stdio + configSchema: + # JSON Schema defining the configuration options for the MCP. + type: object + required: + - sqliteDbPath + properties: + sqliteDbPath: + type: string + description: The full path to the SQLite database file. + commandFunction: + # A function that produces the CLI command to start the MCP on stdio. + |- + config => ({ command: 'uvicorn', args: ['sqlite_explorer:app', '--host', '0.0.0.0', '--port', '8000'], env: { SQLITE_DB_PATH: config.sqliteDbPath } }) \ No newline at end of file