Tekton MCP Server exposes Tekton resources to
Model Context Protocol (MCP) clients. It
currently focuses on tektoncd/pipeline
and supports both stdio and Streamable HTTP transports.
Important
This project is under active development. Test it in a non-production cluster and review the access granted to both the server and the connected MCP client.
The server needs:
- access to a Kubernetes cluster with Tekton Pipelines installed
- a kubeconfig for local use, or an in-cluster service account when deployed to Kubernetes
- Go at the version in
go.modwhen building from source
kubectl and
ko are also required to deploy the manifests from a
source checkout.
git clone https://github.com/tektoncd/mcp-server.git
cd mcp-server
mkdir -p bin
go build -mod=vendor -o bin/tekton-mcp-server ./cmd/tekton-mcp-serverThe server uses the standard Kubernetes client configuration. Confirm that
kubectl config current-context points to the intended cluster before running
it.
Use stdio when an MCP client starts the server as a subprocess:
./bin/tekton-mcp-server -transport=stdioA typical MCP client entry looks like this; adapt the surrounding configuration to the client being used:
{
"mcpServers": {
"tekton": {
"command": "/absolute/path/to/bin/tekton-mcp-server",
"args": ["-transport=stdio"]
}
}
}Bind to localhost for local development:
./bin/tekton-mcp-server -transport=http -address=127.0.0.1:8080Connect the MCP client to http://127.0.0.1:8080.
Set KO_DOCKER_REPO to a registry accessible to the cluster, then build the
image and apply the manifests:
export KO_DOCKER_REPO=registry.example.com/YOUR-USER/mcp-server
ko apply -R -f config/
kubectl -n tekton-mcp rollout status deployment/tekton-mcp-serverFor local access to the in-cluster service:
kubectl -n tekton-mcp port-forward service/tekton-mcp-server 8080:8080ko delete -R -f config/ removes every included resource, including the
tekton-mcp namespace and anything else stored in that namespace. Use it only
when that destructive cleanup is intended.
The server uses Tekton v1 resources and is built and tested against the
Kubernetes, Tekton Pipelines, and MCP Go SDK versions recorded in
go.mod. Until a broader compatibility matrix is published, test
the server with the exact cluster versions on which it will run.
The server can read and modify Tekton resources using the permissions of its kubeconfig or service account. Several tools create, patch, start, restart, and delete resources, so use a dedicated least-privilege identity and a disposable namespace while evaluating it.
The HTTP transport does not provide authentication or TLS. Do not expose it to an untrusted network without an authenticating, TLS-terminating proxy. The included development manifests grant cluster-wide permissions and should be reviewed before use on a shared cluster.
Report vulnerabilities privately through the project security policy. Do not open a public issue for a suspected vulnerability.
See DEVELOPMENT.md for build, test, dependency update,
cluster deployment, and debugging instructions. Contributions follow the
process in CONTRIBUTING.md.
The project was proposed and accepted in
tektoncd/community#1194.
namespace: Namespace to list Pipelines from (string, required)prefix: Name prefix to filter Pipelines (string, optional)label-selector: Label selector to filter Pipelines (string, optional)
namespace: Namespace to list PipelineRuns from (string, required)prefix: Name prefix to filter PipelineRuns (string, optional)label-selector: Label selector to filter PipelineRuns (string, optional)
namespace: Namespace to list Tasks from (string, required)prefix: Name prefix to filter Tasks (string, optional)label-selector: Label selector to filter Tasks (string, optional)
namespace: Namespace to list TaskRuns from (string, required)prefix: Name prefix to filter TaskRuns (string, optional)label-selector: Label selector to filter TaskRuns (string, optional)
namespace: Namespace to list Step Actions from (string, required)prefix: Name prefix to filter Step Actions (string, optional)label-selector: Label selector to filter Step Actions (string, optional)
namespace: Namespace where the Pipeline will be created (string, optional, default: "default")yaml: YAML definition of the Pipeline (string, required)
namespace: Namespace where the Task will be created (string, optional, default: "default")yaml: YAML definition of the Task (string, required)
namespace: Namespace where the PipelineRun will be created (string, optional, default: "default")yaml: YAML definition of the PipelineRun (string, optional)generateName: Generate name prefix for the PipelineRun (string, optional)
namespace: Namespace where the TaskRun will be created (string, optional, default: "default")yaml: YAML definition of the TaskRun (string, optional)generateName: Generate name prefix for the TaskRun (string, optional)
name: Name of the Pipeline to get (string, required)namespace: Namespace of the Pipeline (string, optional, default: "default")output: Output format - json or yaml (string, optional, default: "yaml")
name: Name of the Task to get (string, required)namespace: Namespace of the Task (string, optional, default: "default")output: Output format - json or yaml (string, optional, default: "yaml")
name: Name of the PipelineRun to get (string, required)namespace: Namespace of the PipelineRun (string, optional, default: "default")output: Output format - json or yaml (string, optional, default: "yaml")
name: Name of the TaskRun to get (string, required)namespace: Namespace of the TaskRun (string, optional, default: "default")output: Output format - json or yaml (string, optional, default: "yaml")
name: Name or reference of the TaskRun to get logs from (string, required)namespace: Namespace where the TaskRun is located (string, optional, default: "default")
name: Name of the Pipeline to update (string, required)namespace: Namespace of the Pipeline (string, optional, default: "default")yaml: Updated YAML definition of the Pipeline (string, required)
name: Name of the Task to update (string, required)namespace: Namespace of the Task (string, optional, default: "default")yaml: Updated YAML definition of the Task (string, required)
name: Name of the Pipeline to patch (string, required)namespace: Namespace of the Pipeline (string, optional, default: "default")patch: JSON patch to apply to the Pipeline (string, required)
name: Name of the Pipeline to delete (string, required)namespace: Namespace of the Pipeline (string, optional, default: "default")
name: Name of the Task to delete (string, required)namespace: Namespace of the Task (string, optional, default: "default")
name: Name of the PipelineRun to delete (string, required)namespace: Namespace of the PipelineRun (string, optional, default: "default")
name: Name of the TaskRun to delete (string, required)namespace: Namespace of the TaskRun (string, optional, default: "default")
namespace: Namespace to delete PipelineRuns from (string, optional, default: "default")labelSelector: Label selector to filter PipelineRuns to delete (string, optional)fieldSelector: Field selector to filter PipelineRuns to delete (string, optional)
name: Name or reference of the Pipeline to start (string, required)namespace: Namespace where the Pipeline is located (string, optional, default: "default")
name: Name or reference of the Task to start (string, required)namespace: Namespace where the Task is located (string, optional, default: "default")
name: Name or reference of the PipelineRun to restart (string, required)namespace: Namespace where the PipelineRun is located (string, optional, default: "default")
name: Name or reference of the TaskRun to restart (string, required)namespace: Namespace where the TaskRun is located (string, optional, default: "default")
The MCP server provides integration with Artifact Hub to discover, install, and trigger Tekton tasks and pipelines from the community catalog.
query: Search query to filter tasks (string, optional)limit: Maximum number of results to return (integer, optional, default: 20)
query: Search query to filter pipelines (string, optional)limit: Maximum number of results to return (integer, optional, default: 20)
packageId: The Artifact Hub package ID of the task to install (string, required)version: Version of the task to install (string, optional)namespace: Namespace where the task will be installed (string, optional, default: "default")
packageId: The Artifact Hub package ID of the pipeline to install (string, required)version: Version of the pipeline to install (string, optional)namespace: Namespace where the pipeline will be installed (string, optional, default: "default")
name: Name of the installed task to trigger (string, required)namespace: Namespace where the task is located (string, optional, default: "default")params: Parameters to pass to the task (object, optional)
name: Name of the installed pipeline to trigger (string, required)namespace: Namespace where the pipeline is located (string, optional, default: "default")params: Parameters to pass to the pipeline (object, optional)