MCP ExplorerExplorer

Openstack Mcp Server

@sbekkermon 17 days ago
1 Apache-2.0
FreeCommunity
AI Systems
Openstack MCP Server

Overview

What is Openstack Mcp Server

OpenStack MCP Server is a Model Context Protocol (MCP) server that enables seamless integration with the OpenStack API, facilitating efficient communication and management of cloud resources.

Use cases

Use cases include managing cloud resources in a multi-tenant environment, automating deployment processes, and integrating various cloud services through the OpenStack API.

How to use

To use OpenStack MCP Server, first build the application container image using the Podman command. Then, create a .env file to configure essential environment variables, followed by a clouds.yaml file for authentication details to connect to your OpenStack environment.

Key features

Key features include seamless integration with OpenStack API, customizable environment configurations through .env and clouds.yaml files, and support for various networking interfaces and ports.

Where to use

OpenStack MCP Server is suitable for cloud computing environments, particularly those utilizing OpenStack for resource management and orchestration.

Content

OpenStack MCP Server

OpenStack MCP Server is a Model Context Protocol (MCP) server that provides seamless integration with OpenStack API.


🚀 Deployment

To build the application container image, use the following Podman command:

podman build . -t openstack_mcp_server

▶️ Starting the Server

To start the OpenStack MCP Server, follow these steps:

1. Create .env file

Create a file named .env in the root directory of the project. This file will store essential environment variables for the server.

OS_CLOUD=overcloud
OS_CLOUD_CONF_PATH=/server/clouds.yaml
OS_MCP_SERVER_HOST=0.0.0.0
OS_MCP_SERVER_PORT=9001

Variable Explanations

  • OS_CLOUD: Specifies the name of the cloud configuration to use from your clouds.yaml file.
  • OS_CLOUD_CONF_PATH: Defines the path to the clouds.yaml file.
  • OS_MCP_SERVER_HOST: Sets the IP address the MCP server will listen on. 0.0.0.0 means it will listen on all available network interfaces.
  • OS_MCP_SERVER_PORT: Sets the port number the MCP server will use.

2. Create clouds.yaml

Create a clouds.yaml file. This file contains the authentication details required to connect to your OpenStack environment. Ensure this file is placed at the path specified by OS_CLOUD_CONF_PATH in your .env file.

clouds:
  overcloud: # This should match OS_CLOUD in your .env file
    auth:
      auth_url: http://X.X.X.X:5000
      password: PASSWORD
      project_domain_name: Default
      project_name: admin
      user_domain_name: Default
      username: admin
    cacert: ''
    identity_api_version: '3'
    region_name: regionOne
    volume_api_version: '3'

⚠️ Important:

  • Replace http://X.X.X.X:5000 with the actual Keystone authentication URL of your OpenStack cloud.
  • Replace PASSWORD with your actual password for the specified user.
  • Adjust other parameters like project_name, username, region_name, etc., to match your specific OpenStack setup.

Run the Application

podman run -d --name openstack_mcp_server \
  -p 9001:9001 \
  --env-file .env \
  -v $(pwd)/clouds.yaml:/server/clouds.yaml:Z \
  localhost/openstack_mcp_server:latest

Examples

Openstack MCP client

How to run the demo MCP client

cd examples/
uv run osp_mcp_client.py --llm_api_url https://X.X.X.X/v1 \
    --llm_api_key XXXX \
    --model_name granite-3-8b-instruct \
    --mcp_url http://X.X.X.X:9001/sse

Tools

No tools

Comments