Skip to content

Commit 6db41f1

Browse files
authored
Add CockroachDB MCP server (#241)
Claude-Session: https://claude.ai/code/session_01S58U7phvDgphx6ZTXuWMJQ Signed-off-by: Mohammod Al Amin Ashik <maa.ashik00@gmail.com>
1 parent a1726d8 commit 6db41f1

1 file changed

Lines changed: 145 additions & 0 deletions

File tree

Lines changed: 145 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,145 @@
1+
{
2+
"$schema": "../schemas/server-definition.schema.json",
3+
"id": "com.cockroachdb-mcp-docker",
4+
"name": "CockroachDB (Docker)",
5+
"alias": "cockroachdb",
6+
"description": "Connect to CockroachDB clusters via Docker. Run SQL queries and transactions, manage databases, tables, indexes, users and privileges, monitor cluster health and jobs, and perform vector search, backups, changefeeds, and multi-region operations.",
7+
"logo": "https://avatars.githubusercontent.com/u/105490765?v=4",
8+
"schema_version": "2.1",
9+
"categories": [
10+
"database"
11+
],
12+
"tags": [
13+
"cockroachdb",
14+
"crdb",
15+
"database",
16+
"sql",
17+
"distributed",
18+
"postgres",
19+
"docker"
20+
],
21+
"transport": {
22+
"type": "stdio",
23+
"command": "docker",
24+
"args": [
25+
"run",
26+
"-i",
27+
"--rm",
28+
"-e",
29+
"CRDB_HOST",
30+
"-e",
31+
"CRDB_PORT",
32+
"-e",
33+
"CRDB_DATABASE",
34+
"-e",
35+
"CRDB_USERNAME",
36+
"-e",
37+
"CRDB_PWD",
38+
"-e",
39+
"CRDB_SSL_MODE",
40+
"mcp/cockroachdb:latest"
41+
],
42+
"env": {
43+
"CRDB_HOST": "${input:CRDB_HOST}",
44+
"CRDB_PORT": "${input:CRDB_PORT}",
45+
"CRDB_DATABASE": "${input:CRDB_DATABASE}",
46+
"CRDB_USERNAME": "${input:CRDB_USERNAME}",
47+
"CRDB_PWD": "${input:CRDB_PWD}",
48+
"CRDB_SSL_MODE": "${input:CRDB_SSL_MODE}"
49+
},
50+
"metadata": {
51+
"inputs": [
52+
{
53+
"id": "CRDB_HOST",
54+
"label": "CockroachDB Host",
55+
"description": "Host name or address of a CockroachDB node or load balancer. Use host.docker.internal instead of localhost/127.0.0.1 to reach a CockroachDB instance running on the host machine.",
56+
"type": "text",
57+
"required": false,
58+
"secret": false,
59+
"default": "127.0.0.1",
60+
"placeholder": "host.docker.internal"
61+
},
62+
{
63+
"id": "CRDB_PORT",
64+
"label": "CockroachDB Port",
65+
"description": "Port number of the SQL interface of the CockroachDB node or load balancer.",
66+
"type": "number",
67+
"required": false,
68+
"secret": false,
69+
"default": "26257",
70+
"placeholder": "26257"
71+
},
72+
{
73+
"id": "CRDB_DATABASE",
74+
"label": "Database",
75+
"description": "Database name to use as the current database.",
76+
"type": "text",
77+
"required": false,
78+
"secret": false,
79+
"default": "defaultdb",
80+
"placeholder": "defaultdb"
81+
},
82+
{
83+
"id": "CRDB_USERNAME",
84+
"label": "Username",
85+
"description": "The SQL user that will own the client session.",
86+
"type": "text",
87+
"required": false,
88+
"secret": false,
89+
"default": "root",
90+
"placeholder": "root"
91+
},
92+
{
93+
"id": "CRDB_PWD",
94+
"label": "Password",
95+
"description": "The SQL user's password. Leave empty for insecure clusters that do not require a password.",
96+
"type": "text",
97+
"required": false,
98+
"secret": true,
99+
"placeholder": "********"
100+
},
101+
{
102+
"id": "CRDB_SSL_MODE",
103+
"label": "SSL Mode",
104+
"description": "Which type of secure connection to use. Set to verify-full and provide certificate paths for CockroachDB Cloud or secure clusters.",
105+
"type": "select",
106+
"required": false,
107+
"secret": false,
108+
"default": "disable",
109+
"options": [
110+
{ "value": "disable", "label": "disable" },
111+
{ "value": "allow", "label": "allow" },
112+
{ "value": "prefer", "label": "prefer" },
113+
{ "value": "require", "label": "require" },
114+
{ "value": "verify-ca", "label": "verify-ca" },
115+
{ "value": "verify-full", "label": "verify-full" }
116+
]
117+
}
118+
]
119+
}
120+
},
121+
"auth": {
122+
"type": "api_key",
123+
"instructions": "Provide CockroachDB connection details (host, port, database, username, password). For CockroachDB Cloud or secure clusters, set CRDB_SSL_MODE to verify-full and supply the CA/cert/key paths."
124+
},
125+
"contributor": {
126+
"name": "amineelkouhen",
127+
"github": "amineelkouhen",
128+
"url": "https://github.com/amineelkouhen/mcp-cockroachdb"
129+
},
130+
"links": {
131+
"repository": "https://github.com/amineelkouhen/mcp-cockroachdb",
132+
"homepage": "https://www.cockroachlabs.com",
133+
"documentation": "https://github.com/amineelkouhen/mcp-cockroachdb#readme"
134+
},
135+
"platforms": [
136+
"all"
137+
],
138+
"capabilities": {
139+
"tools": true,
140+
"resources": false,
141+
"prompts": false,
142+
"read_only_mode": false
143+
},
144+
"changelog_url": "https://github.com/amineelkouhen/mcp-cockroachdb/releases"
145+
}

0 commit comments

Comments
 (0)