unity-mcp-server
by somaz94
Unity MCP (Model Context Protocol) Server — exposes a FastMCP-based server for Unity plugin integrations over the StreamableHTTP transport. Bring your own image built from CoplayDev/unity-mcp.
About this chart
unity-mcp-server
Helm chart for the Unity MCP Server — a Model Context Protocol bridge for the Unity editor, served over FastMCP's StreamableHTTP transport.
Bring your own image
This chart ships no default image and does not depend on an upstream Docker build. You must build your own image from the upstream repo and push it to a registry your cluster can pull from.
Minimum Dockerfile:
FROM python:3.12-slim
RUN pip install --no-cache-dir uv
WORKDIR /app
RUN git clone --depth 1 https://github.com/CoplayDev/unity-mcp.git .
# FastMCP 3.2+ is strongly recommended — earlier versions have looser
# handling of session-less GET /mcp requests (see Known limitations).
RUN uv pip install --system --upgrade fastmcp
EXPOSE 8080
# Command/args are driven by the Helm chart (values.yaml: command/args).
Push to your registry (GHCR, ECR, Harbor, …) and set image.repository / image.tag to whatever you pushed. YOUR_TAG in every example below is a placeholder — substitute your build tag (e.g. the upstream release version, a git SHA, a CI build number, …).
image:
repository: ghcr.io/yourorg/unity-mcp-server
tag: YOUR_TAG
What it deploys
| Resource | API | Purpose |
|---|---|---|
Deployment | apps/v1 | Unity MCP server container (FastMCP HTTP transport) |
Service | v1 | ClusterIP by default |
Secret | v1 | Optional — MCP_API_KEY (when apiKey.enabled and no existingSecret) |
HTTPRoute | gateway.networking.k8s.io/v1 | Optional — Gateway API ingress (httproute.enabled) |
Ingress | networking.k8s.io/v1 | Optional — legacy Ingress (ingress.enabled) |
ProxySettingsPolicy | gateway.nginx.org/v1alpha1 | Optional — NGINX Gateway Fabric SSE buffering off |
ServiceAccount | v1 | Optional — dedicated SA for IRSA / image pull secret scoping (serviceAccount.create) |
NetworkPolicy | networking.k8s.io/v1 | Optional — pod-level ingress/egress lock-down (networkPolicy.enabled) |
Versioning
- Chart
version— this chart's own SemVer, bumped on every change. appVersion— the upstreamCoplayDev/unity-mcprelease this chart was tested against.
Prerequisites
- Kubernetes 1.25+
- An image you built from upstream (see above)
- For
httproute.enabled: a Gateway API–compliant controller with a readyGateway - For
nginxGatewayFabric.proxySettings.enabled: NGINX Gateway Fabric specifically; the defaultproxySettings.timeoutneeds NGF 2.6+ (on older NGF setnginxGatewayFabric.proxySettings.timeout: null) - For
ingress.enabled: an Ingress controller
Install
These snippets install the latest published chart. To pin an exact chart version, add --version <x.y.z> — released versions are the GitHub Release tags named unity-mcp-server-<version>.
OCI registry (Helm 3.8+)
helm install unity-mcp oci://ghcr.io/somaz94/charts/unity-mcp-server \
--namespace mcp --create-namespace \
--set image.repository=ghcr.io/yourorg/unity-mcp-server \
--set image.tag=YOUR_TAG \
--set apiKey.value=CHANGE_ME
Classic Helm repo
helm repo add somaz94 https://charts.somaz.blog
helm repo update
helm install unity-mcp somaz94/unity-mcp-server \
--namespace mcp --create-namespace \
-f my-values.yaml
Required values
image.repository— your registry pathimage.tag— pinned tagapiKey.valueorapiKey.existingSecret— whenapiKey.enabled: true(default)
Quick examples
Minimal (cluster-internal access only)
image:
repository: ghcr.io/yourorg/unity-mcp-server
tag: YOUR_TAG
apiKey:
value: super-secret-key
External access via NGINX Gateway Fabric (SSE-friendly)
image:
repository: ghcr.io/yourorg/unity-mcp-server
tag: YOUR_TAG
apiKey:
existingSecret: unity-mcp-api-key # keys: api-key
imagePullSecrets:
- name: ghcr-pull-secret
httproute:
enabled: true
parentRefs:
- name: ngf
namespace: nginx-gateway
hostnames:
- unity-mcp.example.com
rules:
- matches:
- path:
type: PathPrefix
value: /
timeouts:
request: 300s # long-lived SSE connections (ignored by NGF, see below)
backendRequest: 300s
backendRefs:
- {}
nginxGatewayFabric:
proxySettings:
enabled: true # turn off response buffering for SSE
timeout: # NGF ignores HTTPRoute timeouts; this is its equivalent
read: 300s
send: 300s
Pulling the BYOI image from a private registry (chart-managed Secret)
When the chart should also render the kubernetes.io/dockerconfigjson Secret (instead of you creating it ahead of time), set imagePullSecret.create=true and provide the base64-encoded dockerconfigjson blob. The Pod-level imagePullSecrets is then injected into the Deployment automatically; existing imagePullSecrets[] references (BYOIPS) are still honored and merged additively.
Generate dockerconfigjson once with either:
docker login registry.example.com && cat ~/.docker/config.json | base64
# or, without docker, build it via kubectl:
kubectl create secret docker-registry tmp \
--docker-server=registry.example.com \
--docker-username=robot \
--docker-password=<token> \
--dry-run=client -o jsonpath='{.data.\.dockerconfigjson}'
Then in your values:
image:
repository: registry.example.com/library/unity-mcp-server
tag: YOUR_TAG
apiKey:
value: <your-api-key>
imagePullSecret:
create: true
dockerconfigjson: ewogICJhdXRoc... # output from the command above
Legacy Ingress (ingress-nginx)
image:
repository: ghcr.io/yourorg/unity-mcp-server
tag: YOUR_TAG
apiKey:
value: super-secret-key
ingress:
enabled: true
className: nginx
host: unity-mcp.example.com
annotations:
nginx.ingress.kubernetes.io/proxy-buffering: "off"
nginx.ingress.kubernetes.io/proxy-read-timeout: "300"
nginx.ingress.kubernetes.io/proxy-send-timeout: "300"
tls:
- hosts: [unity-mcp.example.com]
secretName: unity-mcp-tls
Values reference
The tables below mirror values.yaml, which is authoritative; values.schema.json enforces the shape.
Top-level blocks:
| Block | Purpose |
|---|---|
image.{repository,tag,pullPolicy} | Your self-built container image (required) |
imagePullSecrets | Reference existing pull secrets (BYOIPS) |
imagePullSecret.{create,name,dockerconfigjson,registry,username,password,email} | Optional chart-managed dockerconfigjson Secret (additive to imagePullSecrets) |
containerPort | FastMCP listen port (default 8080) |
service.{type,port,nodePort,annotations} | Kubernetes Service shape |
command / args | Container entrypoint; defaults match upstream mcp-for-unity |
apiKey.{enabled,value,existingSecret,secretKey} | MCP_API_KEY wiring |
env[] | Extra environment variables |
resources | Requests / limits |
livenessProbe / readinessProbe | tcpSocket by default — do not switch to httpGet /mcp (see Known limitations) |
httproute.* / ingress.* | Two mutually compatible ingress paths |
nginxGatewayFabric.proxySettings.* | NGF ProxySettingsPolicy: buffering.disable: true, plus upstream timeout (connect / read / send, NGF 2.6+). NGF ignores HTTPRoute timeouts, so set them here |
serviceAccount.* | Optional dedicated SA (IRSA / Workload Identity / imagePullSecrets) |
networkPolicy.* | Optional NetworkPolicy (native ingress/egress rules) |
commonLabels / commonAnnotations / resourceMetadata.* | Labels and annotations per resource kind |
specExtra / podTemplateExtra / kubernetesExtra | Escape hatches |
Known limitations
- StreamableHTTP 400 on
GET /mcpwithout a session is spec-compliant. FastMCP requires clients to firstPOST /mcpwithinitialize(receiving anMcp-Session-Idheader) and then open the SSE stream with that header. Pre-sessionGET /mcpprobes will return 400 and clutter logs — not a bug. This is why the default probes aretcpSocket, nothttpGet. FastMCP 3.2+ improves the error responses. /.well-known/oauth-protected-resource404 is also spec-compliant — it declares the server is not OAuth-protected. FastMCP 3.2+ adds a cleaner default handler.- No default image. If you want the upstream FastMCP bootstrap to Just Work, wrap it in your own Dockerfile and CI. See the "Bring your own image" section.
Maintaining this chart
Bumping the Unity MCP Server version
cd charts/unity-mcp-server
./upgrade.sh --dry-run # preview
./upgrade.sh # bump to latest
./upgrade.sh --version 9.7.3 # pin to a specific version
./upgrade.sh --rollback # restore files from backup/
upgrade.sh updates Chart.yaml appVersion only — the image tag is derived from .Chart.AppVersion, so values.yaml is left untouched. It does NOT bump the chart's own SemVer or touch any cluster. After reviewing the diff:
make bump CHART=unity-mcp-server LEVEL=minor
make lint CHART=unity-mcp-server
make template CHART=unity-mcp-server
License
Apache-2.0
Deploy unity-mcp-server with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has unity-mcp-server on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartunity-mcp-server is pinned at v0.2.0 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply