Skip to content

Commit 00665ae

Browse files
committed
Add configuration examples for mise and asdf version managers in MCP documentation
1 parent beb1508 commit 00665ae

File tree

1 file changed

+66
-0
lines changed

1 file changed

+66
-0
lines changed

docs/features/mcp/using-mcp-in-roo.md

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,3 +251,69 @@ For macOS or Linux, you would use a different configuration:
251251
:::
252252

253253
The same approach can be used for other MCP servers on Windows, adjusting the package name as needed for different server types.
254+
255+
### Runtime Version Manager Configuration
256+
257+
When working with multiple versions of programming languages or runtimes, you may use version managers like [asdf](https://asdf-vm.com/) or [mise](https://mise.jdx.dev/) (formerly rtx). These tools help manage multiple runtime versions on a single system. Here's how to configure MCP servers to work with these version managers:
258+
259+
#### mise Configuration Example
260+
261+
[mise](https://mise.jdx.dev/) is a fast, modern runtime version manager that can be used to specify which version of Node.js, Python, or other runtimes to use for your MCP server:
262+
263+
```json
264+
{
265+
"mcpServers": {
266+
"mcp-batchit": {
267+
"command": "mise",
268+
"args": [
269+
"x",
270+
"--",
271+
"node",
272+
"/Users/myself/workspace/mcp-batchit/build/index.js"
273+
],
274+
"disabled": false,
275+
"alwaysAllow": [
276+
"search",
277+
"batch_execute"
278+
]
279+
}
280+
}
281+
}
282+
```
283+
284+
This configuration:
285+
- Uses the `mise` command to manage runtime versions
286+
- The `x` subcommand executes a command with the configured runtime version
287+
- The `--` separates mise arguments from the command to run
288+
- Runs `node` with the specific version configured in your mise settings
289+
- Points to the MCP server JavaScript file
290+
- Automatically allows the "search" and "batch_execute" tools
291+
292+
#### asdf Configuration Example
293+
294+
[asdf](https://asdf-vm.com/) is a popular tool for managing multiple runtime versions. Here's how to configure an MCP server to use a specific Node.js version managed by asdf:
295+
296+
```json
297+
{
298+
"mcpServers": {
299+
"appsignal": {
300+
"command": "/Users/myself/.asdf/installs/nodejs/22.2.0/bin/node",
301+
"args": [
302+
"/Users/myself/Code/Personal/my-mcp/build/index.js"
303+
],
304+
"env": {
305+
"ASDF_NODE_VERSION": "22.2.0"
306+
},
307+
"disabled": false,
308+
"alwaysAllow": []
309+
}
310+
}
311+
}
312+
```
313+
314+
This configuration:
315+
- Directly references the Node.js executable from the asdf installations directory
316+
- Sets the `ASDF_NODE_VERSION` environment variable to ensure consistent version use
317+
- Points to the MCP server JavaScript file
318+
319+
Using version managers ensures that your MCP servers run with the correct runtime version, regardless of the system's default version, providing consistency across different environments and preventing version conflicts.

0 commit comments

Comments
 (0)