k8scortex-mcp

v1.1.3
io.github.apatilgtn/k8scortex-mcp Checked 10 hours ago Published 1 month ago

Kubernetes MCP server: 75 tools for GKE, AKS, EKS, RBAC, audit logging, GitOps, multi-cluster.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

list_pods

Lists pods in a specific namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

get_pod_logs

Retrieves logs for a specific pod.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
podName *stringThe name of the pod
clusterstringTarget cluster name (default: 'default')
containerNamestringOptional: specific container name for multi-container pods
tailLinesnumberNumber of lines to tail from the end of the logs

describe_pod

Shows detailed pod status including container states, conditions, resource settings, and recent events.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
podName *stringThe name of the pod
clusterstringTarget cluster name (default: 'default')

describe_deployment

Shows details of a deployment.

ParameterTypeDescription
deploymentName *stringThe name of the deployment
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

list_nodes

Lists cluster nodes.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')

list_statefulsets

Lists StatefulSets in a specific namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

describe_statefulset

Shows details of a StatefulSet.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
statefulSetName *stringThe name of the StatefulSet
clusterstringTarget cluster name (default: 'default')

list_daemonsets

Lists DaemonSets in a specific namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

describe_daemonset

Shows details of a DaemonSet.

ParameterTypeDescription
daemonSetName *stringThe name of the DaemonSet
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

scale_deployment

Scales replicas for a deployment.

ParameterTypeDescription
deploymentName *stringThe name of the deployment
namespace *stringThe Kubernetes namespace
replicas *numberThe new replica count
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

rollout_status

Checks deployment rollout status (complete, in-progress, or stalled).

ParameterTypeDescription
deploymentName *stringThe name of the deployment
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

rollout_undo

Rolls a deployment back to the previous ReplicaSet template.

ParameterTypeDescription
deploymentName *stringThe name of the deployment
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

restart_pod

Deletes a pod to force a restart. Usually managed by a deployment/replicaset.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
podName *stringThe name of the pod to restart
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

get_configmap

Reads data from a ConfigMap.

ParameterTypeDescription
configMapName *stringThe name of the ConfigMap
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

describe_namespace_quota

Reads resource quotas for a namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

list_events

Lists recent cluster events for a namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

list_persistent_volume_claims

Lists PersistentVolumeClaims in a specific namespace with binding and capacity details.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

get_effective_permissions

Evaluates effective Kubernetes API permissions for a ServiceAccount using SubjectAccessReview checks.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace of the ServiceAccount
serviceAccountName *stringThe ServiceAccount name to inspect
clusterstringTarget cluster name (default: 'default')

get_hpa_status

Retrieves Horizontal Pod Autoscaler metrics and status.

ParameterTypeDescription
hpaName *stringThe name of the HPA
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

list_warning_events

Filters cluster events for warnings in a namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

get_node_pressure

Analyzes node resource pressure for a specific node.

ParameterTypeDescription
nodeName *stringThe name of the node
clusterstringTarget cluster name (default: 'default')

list_clusters

Lists all registered Kubernetes clusters known to K8sCortex (kubeconfig contexts, cluster registry file, or Azure Key Vault), with provider, cloud, region and labels.

ParameterTypeDescription
cloudstringOnly clusters on this cloud (e.g. eks, gke, aks, openshift, local)
labelSelectorstringOnly clusters whose registry labels match, e.g. 'env=prod,team=payments'
regionstringOnly clusters in this region

get_cluster_info

Returns Kubernetes version, platform (EKS/GKE/AKS/OpenShift), node count and node details for a given cluster.

ParameterTypeDescription
cluster *stringThe registered cluster name (e.g. prod-aks-au)

list_jobs

Lists Jobs in a specific namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

create_job

Creates a new Job. Use either basic configuration or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
commandarrayCommand to run (if using basic config)
dryRunbooleanIf true, simulates the action without making changes
imagestringContainer image to run (if using basic config)
jobNamestringThe name of the job to create
yamlManifeststringFull YAML manifest for advanced job creation

list_cronjobs

Lists CronJobs in a specific namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

suspend_cronjob

Suspends an active CronJob.

ParameterTypeDescription
cronJobName *stringThe name of the CronJob to suspend
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

resume_cronjob

Resumes a suspended CronJob.

ParameterTypeDescription
cronJobName *stringThe name of the CronJob to resume
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

create_configmap

Creates a new ConfigMap. Use either basic key-value data or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
configMapNamestringThe name of the ConfigMap to create
dataobjectKey-value string pairs for the ConfigMap data
dryRunbooleanIf true, simulates the action without making changes
yamlManifeststringFull YAML manifest for advanced ConfigMap creation

update_configmap

Updates an existing ConfigMap by patching its data.

ParameterTypeDescription
configMapName *stringThe name of the ConfigMap to update
data *objectKey-value string pairs to merge into the ConfigMap
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

create_secret

Creates a new Opaque Secret. Use either basic stringData or provide a raw YAML manifest. stringData values will be base64-encoded automatically.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes
secretNamestringThe name of the Secret to create
stringDataobjectPlain text key-value pairs. Will be encoded automatically.
yamlManifeststringFull YAML manifest for advanced Secret creation

update_secret

Updates an existing Secret: each key in stringData is added or replaced, and keys you do not pass are kept unchanged. Values are never returned.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
secretName *stringThe name of the Secret to update
stringData *objectPlain text key-value pairs to merge into the Secret. Will be encoded automatically.
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

create_deployment

Creates a new Deployment. Use either basic configuration or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
deploymentNamestringThe name of the deployment to create
dryRunbooleanIf true, simulates the action without making changes
imagestringContainer image to run (if using basic config)
portnumberContainer port to expose (if using basic config)
replicasnumberNumber of replicas (if using basic config)
yamlManifeststringFull YAML manifest for advanced deployment creation

delete_deployment

Deletes an existing Deployment.

ParameterTypeDescription
deploymentName *stringThe name of the deployment to delete
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

create_namespace

Creates a new Kubernetes Namespace.

ParameterTypeDescription
namespaceName *stringThe name of the namespace to create
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

delete_namespace

Deletes an existing Kubernetes Namespace.

ParameterTypeDescription
namespaceName *stringThe name of the namespace to delete
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes

create_horizontal_pod_autoscaler

Creates an HPA for a Deployment. Use either basic configuration or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes
hpaNamestringThe name of the HPA to create
maxReplicasnumberMaximum number of replicas
minReplicasnumberMinimum number of replicas
targetCPUUtilizationPercentagenumberTarget CPU utilization percentage
targetDeploymentstringThe name of the target Deployment to scale
yamlManifeststringFull YAML manifest for advanced HPA creation

create_service

Creates a new Service. Use either basic configuration or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes
portnumberPort the service exposes
selectorobjectLabel selector for the pods (e.g. { app: 'my-app' })
serviceNamestringThe name of the Service to create
targetPortnumberTarget port on the pod
typestringService type (ClusterIP, NodePort, LoadBalancer)
yamlManifeststringFull YAML manifest for advanced Service creation

list_ingresses

Lists Ingress resources in a namespace.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

get_service_endpoints

Shows endpoint addresses backing a Service.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
serviceName *stringService name
clusterstringTarget cluster name (default: 'default')

update_ingress

Updates an existing Ingress. Merges new rules or annotations into the existing Ingress.

ParameterTypeDescription
ingressName *stringThe name of the Ingress to update
namespace *stringThe Kubernetes namespace
annotationsobjectAnnotations to merge
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes
rulesarrayRules to append or replace (advanced usage)

create_network_policy

Creates a new NetworkPolicy. Use either basic configuration or provide a raw YAML manifest.

ParameterTypeDescription
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action without making changes
podSelectorobjectLabel selector for the pods this policy applies to
policyNamestringThe name of the NetworkPolicy
policyTypesarrayList of policy types (Ingress, Egress)
yamlManifeststringFull YAML manifest for advanced NetworkPolicy creation

set_resource_limits

Sets CPU and Memory requests and limits for a specific container in a Deployment.

ParameterTypeDescription
containerName *stringThe name of the container
deploymentName *stringThe name of the Deployment
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')
cpuLimitstringCPU limit (e.g. '500m' or '1')
cpuRequeststringCPU request (e.g. '100m' or '0.1')
dryRunbooleanIf true, simulates the action
memoryLimitstringMemory limit (e.g. '512Mi')
memoryRequeststringMemory request (e.g. '256Mi')

get_resource_recommendations

Suggests optimal resource requests/limits based on current metrics heuristically.

ParameterTypeDescription
deploymentName *stringThe name of the Deployment
namespace *stringThe Kubernetes namespace
clusterstringTarget cluster name (default: 'default')

get_cluster_resource_utilisation

Returns CPU and Memory usage vs capacity across all nodes.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')

cordon_node

Marks a node as unschedulable.

ParameterTypeDescription
nodeName *stringName of the node to cordon
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

uncordon_node

Marks a node as schedulable.

ParameterTypeDescription
nodeName *stringName of the node to uncordon
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

drain_node

Cordons the node and evicts/deletes non-daemonset pods.

ParameterTypeDescription
nodeName *stringName of the node to drain
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action
forcebooleanForce deletion of pods

taint_node

Adds a taint to a node.

ParameterTypeDescription
effect *stringTaint effect (NoSchedule, PreferNoSchedule, NoExecute)
key *stringTaint key
nodeName *stringName of the node
value *stringTaint value
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

remove_taint

Removes a specific taint from a node by key.

ParameterTypeDescription
key *stringTaint key to remove
nodeName *stringName of the node
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

get_gitops_app_status

Gets the health and sync status of an ArgoCD Application or Flux Kustomization.

ParameterTypeDescription
appName *stringThe name of the application/kustomization
engine *stringGitOps engine ('argocd' or 'flux')
namespace *stringThe namespace of the application/kustomization
clusterstringTarget cluster name (default: 'default')

get_gitops_diff

Gets out-of-sync resources (ArgoCD) or managed resource inventory with revision drift (Flux Kustomization).

ParameterTypeDescription
appName *stringThe name of the application/kustomization
engine *stringGitOps engine ('argocd' or 'flux')
namespace *stringThe namespace of the application/kustomization
clusterstringTarget cluster name (default: 'default')

sync_gitops_app

Forces a sync/reconciliation of an ArgoCD Application, Flux Kustomization, or Flux HelmRelease.

ParameterTypeDescription
appName *stringThe name of the application/kustomization/helmrelease
engine *stringGitOps engine ('argocd' or 'flux')
namespace *stringThe namespace of the application/kustomization/helmrelease
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action
resourceTypestringFlux only: 'kustomization' (default) or 'helmrelease'

compare_clusters

Compares the running version/state of an application across two clusters.

ParameterTypeDescription
appName *stringThe name of the application/kustomization
clusterA *stringFirst cluster to compare
clusterB *stringSecond cluster to compare
engine *stringGitOps engine ('argocd' or 'flux')
namespace *stringThe namespace of the application/kustomization

list_flux_kustomizations

Lists all Flux Kustomizations in a namespace with their ready/suspended/revision status.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')
namespacestringNamespace to list Kustomizations in (omit for all namespaces)

list_flux_helm_releases

Lists all Flux HelmReleases in a namespace with chart name, version, and ready/suspended status.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')
namespacestringNamespace to list HelmReleases in (omit for all namespaces)

get_flux_helm_release

Gets detailed status of a Flux HelmRelease including chart version, values, and condition history.

ParameterTypeDescription
name *stringName of the HelmRelease
namespace *stringNamespace of the HelmRelease
clusterstringTarget cluster name (default: 'default')

list_flux_sources

Lists Flux source objects (GitRepository, HelmRepository, OCIRepository, Bucket) with their URL, ref, and ready status.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')
namespacestringNamespace to list sources in (omit for all namespaces)
sourceTypestringSource kind: 'gitrepository' | 'helmrepository' | 'ocirepository' | 'bucket' (omit for all)

suspend_flux_resource

Suspends reconciliation of a Flux Kustomization or HelmRelease to pause automated deployments.

ParameterTypeDescription
name *stringName of the resource
namespace *stringNamespace of the resource
resourceType *string'kustomization' or 'helmrelease'
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

resume_flux_resource

Resumes reconciliation of a suspended Flux Kustomization or HelmRelease.

ParameterTypeDescription
name *stringName of the resource
namespace *stringNamespace of the resource
resourceType *string'kustomization' or 'helmrelease'
clusterstringTarget cluster name (default: 'default')
dryRunbooleanIf true, simulates the action

list_flux_alerts

Lists Flux Notification Alert objects showing which events trigger which providers.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')
namespacestringNamespace to list Alerts in (omit for all namespaces)

list_k8s_resources

Generic read: list Kubernetes resources by group/version/resource.

ParameterTypeDescription
resource *stringPlural resource name (e.g. 'statefulsets', 'daemonsets', 'persistentvolumeclaims', 'roles')
version *stringAPI version (e.g. 'v1')
apiGroupstringAPI group (e.g. 'apps', 'rbac.authorization.k8s.io'). Use '' or 'core' for core/v1 resources.
clusterstringTarget cluster name (default: 'default')
labelSelectorstringOptional label selector
namespacestringNamespace for namespaced resources
namespacedbooleanWhether the target resource is namespaced

get_k8s_resource

Generic read: get a single Kubernetes resource by group/version/resource/name.

ParameterTypeDescription
name *stringResource name
resource *stringPlural resource name
version *stringAPI version (e.g. 'v1')
apiGroupstringAPI group (e.g. 'apps', 'rbac.authorization.k8s.io'). Use '' or 'core' for core/v1 resources.
clusterstringTarget cluster name (default: 'default')
namespacestringNamespace for namespaced resources
namespacedbooleanWhether the target resource is namespaced

list_node_pools

Groups nodes by managed-cloud node pool labels (AKS/EKS/GKE) and reports pool health.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')

get_node_pool_detail

Returns detailed node, spot/preemptible, and optional metrics view for a specific node pool.

ParameterTypeDescription
poolName *stringNode pool name
clusterstringTarget cluster name (default: 'default')

get_workload_identity_config

Returns workload identity annotation configuration for a ServiceAccount (AKS/EKS/GKE conventions).

ParameterTypeDescription
namespace *stringServiceAccount namespace
serviceAccountName *stringServiceAccount name
clusterstringTarget cluster name (default: 'default')

validate_workload_identity

Validates identity chain from ServiceAccount annotation to pods using that ServiceAccount.

ParameterTypeDescription
namespace *stringServiceAccount namespace
serviceAccountName *stringServiceAccount name
clusterstringTarget cluster name (default: 'default')

list_pod_disruption_budgets

Lists PodDisruptionBudgets in a namespace with budget satisfaction status.

ParameterTypeDescription
namespace *stringNamespace
clusterstringTarget cluster name (default: 'default')

get_pdb_status

Returns detailed status and covered pods for a PodDisruptionBudget.

ParameterTypeDescription
namespace *stringNamespace
pdbName *stringPDB name
clusterstringTarget cluster name (default: 'default')

list_vpas

Lists VerticalPodAutoscaler objects in a namespace and their update mode/recommendation state.

ParameterTypeDescription
namespace *stringNamespace
clusterstringTarget cluster name (default: 'default')

get_vpa_recommendation

Returns VPA recommendation lower/target/upper bounds for a workload when available.

ParameterTypeDescription
namespace *stringNamespace
vpaName *stringVPA object name
clusterstringTarget cluster name (default: 'default')

list_storage_classes

Lists StorageClasses and indicates default class.

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')

get_storage_class

Returns details for a specific StorageClass.

ParameterTypeDescription
storageClassName *stringStorageClass name
clusterstringTarget cluster name (default: 'default')

get_addon_health

Checks health of common kube-system addons (CoreDNS, metrics-server, kube-proxy, CNI).

ParameterTypeDescription
clusterstringTarget cluster name (default: 'default')

list_limit_ranges

Lists LimitRange objects in a namespace and default resource constraints.

ParameterTypeDescription
namespace *stringNamespace
clusterstringTarget cluster name (default: 'default')