Skip to main content
Glama

Shell Command MCP Server

by kaznak

execute-bash-script-sync

Execute bash scripts synchronously in a secure Docker container, ensuring each command completes before proceeding. Ideal for tasks requiring sequential execution and precise control over script timing and environment variables.

Instructions

This tool executes shell scripts synchronously 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 this execute-bash-script-sync tool unless you really need to, and use the 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.\nSet environment variables using this option instead of using export command in the script.\n", "type": "object" }, "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