Skip to content

Commit ed40a3e

Browse files
committed
update configuration to use host.docker.internal by default
1 parent da9ff38 commit ed40a3e

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ RUN pip install --no-cache-dir -r requirements.txt
1515
COPY src/ /app/src
1616

1717
# Set environment variables for MySQL (these can be overwritten with `docker run -e`)
18-
ENV MYSQL_HOST=localhost
18+
ENV MYSQL_HOST=host.docker.internal
19+
ENV MYSQL_PORT=3306
1920
ENV MYSQL_USER=your_username
2021
ENV MYSQL_PASSWORD=your_password
2122
ENV MYSQL_DATABASE=your_database

smithery.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,27 @@ startCommand:
66
# JSON Schema defining the configuration options for the MCP.
77
type: object
88
required:
9-
- mysqlHost
109
- mysqlUser
1110
- mysqlPassword
1211
- mysqlDatabase
1312
properties:
1413
mysqlHost:
1514
type: string
16-
description: The hostname of the MySQL server.
15+
description: "The hostname of the MySQL server. Use localhost for local connections or a specific address for remote databases. For Docker, host.docker.internal allows accessing the host machine."
16+
default: "host.docker.internal"
1717
mysqlPort:
1818
type: number
19-
description: The port of the MySQL server (default: 3306).
19+
description: "The port of the MySQL server (default: 3306)."
2020
default: 3306
2121
mysqlUser:
2222
type: string
23-
description: The username for MySQL authentication.
23+
description: "The username for MySQL authentication."
2424
mysqlPassword:
2525
type: string
26-
description: The password for MySQL authentication.
26+
description: "The password for MySQL authentication."
2727
mysqlDatabase:
2828
type: string
29-
description: The database to connect to.
29+
description: "The database to connect to."
3030
commandFunction:
3131
# A function that produces the CLI command to start the MCP on stdio.
3232
|-

0 commit comments

Comments
 (0)