Skip to main content
Glama

Shell Command MCP Server

by kaznak

execute-bash-script-async

Execute bash scripts asynchronously to run multiple commands in parallel, reducing waiting time and improving efficiency. Set environment variables, specify working directories, and manage output modes for optimized script execution in a secure Docker container environment.

Instructions

This tool executes shell scripts asynchronously in bash. Executing each command creates a new bash process. Synchronous execution requires to wait the scripts completed. Asynchronous execution makes it possible to execute multiple scripts in parallel. You can reduce waiting time by planning in advance which shell scripts need to be executed and executing them in parallel. Avoid using execute-bash-script-sync tool unless you really need to, and use this execute-bash-script-async tool whenever possible.

Input Schema

NameRequiredDescriptionDefault
commandYesThe bash script to execute
optionsYes

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "command": { "description": "The bash script to execute", "type": "string" }, "options": { "additionalProperties": false, "properties": { "cwd": { "description": "The working directory to execute the script.\nuse this option argument to avoid cd command in the first line of the script.\n`~` and environment variable is not supported. use absolute path instead.\n", "type": "string" }, "env": { "additionalProperties": { "type": "string" }, "description": "The environment variables for the script.\n Set environment variables using this option instead of using export command in the script.\n ", "type": "object" }, "outputMode": { "default": "complete", "description": "The output mode for the script.\n- complete: Notify when the command is completed\n- line: Notify on each line of output\n- chunk: Notify on each chunk of output\n- character: Notify on each character of output\n", "enum": [ "complete", "line", "character", "chunk" ], "type": "string" }, "timeout": { "description": "The timeout in milliseconds.\nSet enough long timeout even if you don't need to set timeout to avoid unexpected blocking.\n", "exclusiveMinimum": 0, "type": "integer" } }, "type": "object" } }, "required": [ "command", "options" ], "type": "object" }

Other Tools from Shell Command MCP Server

Related Tools

    MCP directory API

    We provide all the information about MCP servers via our MCP API.

    curl -X GET 'https://glama.ai/api/mcp/v1/servers/kaznak/shell-command-mcp'

    If you have feedback or need assistance with the MCP directory API, please join our Discord server