Set up the MCP server using Docker
Running the Loggly Model Context Protocol (MCP) server locally in a Docker container provides an isolated, self-managed deployment. Before you begin, install Docker and make sure it is running. For installation instructions and system requirements, see Get Docker.
The examples on this page use a specific image version. Before running the container, check Docker Hub for the latest available Loggly MCP server image version, and replace the version tag in these commands if desired.
Configure Loggly credentials
The MCP server requires the following environment variables:
-
SERVER_TOKEN— Your Loggly API token with Read access. -
PRODUCT_DOMAIN— Your Loggly product domain or subdomain.
Never paste your Loggly API token into an AI prompt or a shared configuration. Keep credentials outside the AI model's accessible context whenever possible.
-
Download the Docker image, replacing the tag with the required version:
IMAGE=solarwinds/loggly-mcp-server:0.1.0 docker pull "$IMAGE" -
Start the local container. For a local-only deployment, supply your credentials as Docker environment variables: replace
{your-loggly-api-token}with a Loggly API token that has Read access, and{your-loggly-subdomain}with your Loggly product domain.docker run --rm --name loggly-mcp-server \ --read-only \ --tmpfs /tmp:rw,noexec,nosuid,size=16m \ --tmpfs /app/logs:rw,noexec,nosuid,size=16m,uid=10001,gid=10001 \ --security-opt=no-new-privileges --cap-drop=ALL \ --cpus=1 --memory=512m --pids-limit=64 \ -e SERVER_TOKEN="{your-loggly-api-token}" \ -e PRODUCT_DOMAIN="{your-loggly-subdomain}" \ -e MCP_HOST=0.0.0.0 \ -p 127.0.0.1:8000:8000 \ "$IMAGE"The server is available at
http://localhost:8000/mcp.To stop the server, run:
docker stop loggly-mcp-server -
If you encounter SSL issues caused by your corporate VPN or certificate chain, run the following command instead. Replace the certificate bundle path with the path for your environment.
docker run --rm --name loggly-mcp-server \ --read-only \ --tmpfs /tmp:rw,noexec,nosuid,size=16m \ --tmpfs /app/logs:rw,noexec,nosuid,size=16m,uid=10001,gid=10001 \ --security-opt=no-new-privileges --cap-drop=ALL \ --cpus=1 --memory=512m --pids-limit=64 \ -v "$PWD/corporate-ca-bundle.pem:/etc/ssl/certs/corporate-ca-bundle.pem:ro" \ -e SSL_CERT_FILE=/etc/ssl/certs/corporate-ca-bundle.pem \ -e SERVER_TOKEN="{your-loggly-api-token}" \ -e PRODUCT_DOMAIN="{your-loggly-subdomain}" \ -e MCP_HOST=0.0.0.0 \ -p 127.0.0.1:8000:8000 \ "$IMAGE"
For help with Docker commands, options, and troubleshooting, see the Docker CLI reference.
After the server is running successfully, configure your MCP client. See Configure an AI client to use the Loggly MCP server for more information.