For the complete documentation index, see llms.txt. This page is also available as Markdown.

Installation

Runtime prerequisites

Installing the mcpd binary is separate from installing MCP server runtimes. After installation, install only the runtime(s) your servers use: uv for uvx::..., npx for npx::..., and Docker for docker::.... See Requirements for details.

via Homebrew

Add the Mozilla.ai tap:

brew tap mozilla-ai/tap

Then install mcpd:

brew install mcpd

Or install directly from the cask:

brew install --cask mozilla-ai/tap/mcpd

via GitHub releases

Official releases can be found on the mcpd GitHub releases page.

The following is an example of manually downloading and installing mcpd using curl and jq by running install_mcpd:

function install_mcpd() {
    command -v curl >/dev/null || { echo "curl not found"; return 1; }
    command -v jq >/dev/null || { echo "jq not found"; return 1; }

    latest_version=$(curl -s https://api.github.com/repos/mozilla-ai/mcpd/releases/latest | jq -r .tag_name)
    os=$(uname)
    arch=$(uname -m)

    zip_name="mcpd_${os}_${arch}.tar.gz"
    url="https://github.com/mozilla-ai/mcpd/releases/download/${latest_version}/${zip_name}"

    echo "Downloading: $url"
    curl -sSL "$url" -o "$zip_name" || { echo "Download failed"; return 1; }

    echo "Extracting: $zip_name"
    tar -xzf "$zip_name" mcpd || { echo "Extraction failed"; return 1; }

    echo "Installing to /usr/local/bin"
    sudo mv mcpd /usr/local/bin/mcpd && sudo chmod +x /usr/local/bin/mcpd || { echo "Install failed"; return 1; }

    rm -f "$zip_name"
    echo "mcpd installed successfully"
}

macOS Gatekeeper quarantine

If you're on macOS, remove the quarantine flag before running mcpd:

via local Go binary build

Run with Docker

mcpd is available as the Docker image mzdotai/mcpd.

Dockerfile environment variables

The Dockerfile defines sensible defaults for configuration via environment variables. These can be overridden at runtime using docker run -e KEY=VALUE.

Default environment variables

Name
Default Value

MCPD_API_PORT

8090

MCPD_LOG_LEVEL

info

MCPD_LOG_PATH

/var/log/mcpd/mcpd.log

MCPD_CONFIG_FILE

/etc/mcpd/.mcpd.toml

MCPD_RUNTIME_FILE

/home/mcpd/.config/mcpd/secrets.prod.toml

To run mcpd with Docker, map the required port and bind mount your .mcpd.toml configuration file and runtime secrets file:

Mounting plugin binaries

If you have [plugins] configured, bind mount the plugin directory as well and point [plugins].dir at the in-container path:

Running Docker-based MCP servers from containerized mcpd

If your MCP servers use the Docker runtime, mount the host's Docker socket to allow mcpd to manage containers on the host:

If Docker-based MCP servers do not work when mcpd itself is running in Docker, see Troubleshooting.

CI/CD Deployment (GitHub Actions)

For automated deployments, a reference GitHub Actions workflow is available in the repository that demonstrates:

  • Version-pinned deployments using release tags

  • Secret resolution from GitHub Secrets into a .env file for Docker

  • Configuration validation

See the following files:

Use mcpd config export to generate the portable execution context required for deployment.

Last updated