Skip to content

Deployment: Dockerfile and Smithery config #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
FROM python:3.13-slim

# Install build dependencies needed for building Python packages
RUN apt-get update && apt-get install -y gcc build-essential && rm -rf /var/lib/apt/lists/*

# Set work directory
WORKDIR /app

# Copy project files
COPY . /app

# Upgrade pip
RUN pip install --upgrade pip

# Install the package and its dependencies
RUN pip install .

# Set the entrypoint to the MCP server command
CMD ["adb-mysql-mcp-server"]
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
# Adb MySQL MCP Server
[![smithery badge](https://smithery.ai/badge/@aliyun/alibabacloud-adb-mysql-mcp-server)](https://smithery.ai/server/@aliyun/alibabacloud-adb-mysql-mcp-server)

Adb MySQL MCP Server serves as a universal interface between AI Agents and Adb MySQL databases. It enables seamless communication between AI Agents and Adb MySQL, helping AI Agents
retrieve Adb MySQL database metadata and execute SQL operations.

## 1. MCP Client Configuration

### Installing via Smithery

To install Adb MySQL MCP Server for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@aliyun/alibabacloud-adb-mysql-mcp-server):

```bash
npx -y @smithery/cli install @aliyun/alibabacloud-adb-mysql-mcp-server --client claude
```

### Mode 1: Using Local File

- #### Download the GitHub repository
Expand Down Expand Up @@ -128,4 +137,4 @@ uv --directory /path/to/alibabacloud-adb-mysql-mcp-server run adb-mysql-mcp-serv

- ### Prompts

Not provided at the present moment.
Not provided at the present moment.
52 changes: 52 additions & 0 deletions smithery.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# 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:
- adbMysqlHost
- adbMysqlUser
- adbMysqlPassword
- adbMysqlDatabase
properties:
adbMysqlHost:
type: string
description: Hostname or IP address of the Adb MySQL server
adbMysqlPort:
type: number
default: 3306
description: Port number of the Adb MySQL server
adbMysqlUser:
type: string
default: ""
description: Username for the Adb MySQL database
adbMysqlPassword:
type: string
default: ""
description: Password for the Adb MySQL database
adbMysqlDatabase:
type: string
default: ""
description: Name of the Adb MySQL database
commandFunction:
# A JS function that produces the CLI command based on the given config to start the MCP on stdio.
|-
(config) => ({
command: 'adb-mysql-mcp-server',
args: [],
env: {
ADB_MYSQL_HOST: config.adbMysqlHost,
ADB_MYSQL_PORT: String(config.adbMysqlPort || 3306),
ADB_MYSQL_USER: config.adbMysqlUser,
ADB_MYSQL_PASSWORD: config.adbMysqlPassword,
ADB_MYSQL_DATABASE: config.adbMysqlDatabase
}
})
exampleConfig:
adbMysqlHost: 127.0.0.1
adbMysqlPort: 3306
adbMysqlUser: root
adbMysqlPassword: secret
adbMysqlDatabase: sample_db