kubiya-runner
by Kubiya AI
A Helm chart for Kubiya Runner deployment
About this chart
Kubiya Runner
A Helm chart for deploying the Kubiya Runner.
Table of Contents
- Kubiya Runner
- Table of Contents
- Overview
- Directory Structure
- Prerequisites
- Permissions
- Components
- Agent Manager
- Kubiya Operator
- Tool Manager
- Workflow Engine
- Image Updater
- Dependencies & Compatibility Matrix
- Helm Dependencies
- Container Images
- Monitoring & Telemetry
- Security
- Architecture
- Grafana Alloy Configuration
- Azure Prometheus Integration
- Grafana Dashboards
- Single View Runners Cumulative Health Score
- Health Overview by Components
- Runner Health Overview
- Tool Manager Dashboard
- Agent Manager Dashboard
- Kubernetes State Dashboard
- Alloy Dashboard
- Blackbox Exporter Dashboards
- Dashboards as a Code
- K8s Resources Definitions
- Security
- Optional Permissions Extensions:
- Deployment
- Minimum Required Configuration & Values Passing
- Installation
- Update
- Using Name Overrides
Overview
This repository contains the Helm chart for deploying the Kubiya Runner, a key component of the Kubiya platform for orchestrating and managing automation workflows.
Directory Structure
kubiya-runner/
├── Chart.yaml # Chart metadata
├── values.yaml # Default values for the chart
├── templates/ # Templates files
│ ├── components/ # Runner Components
│ │ ├── agent-manager/ # Manages Kubiya agents lifecycle
│ │ ├── kubiya-operator/ # Controls operational aspects
│ │ ├── tool-manager/ # Handles tool execution
│ │ └── image-updater/ # Automatic image updates
│ ├── alloy-configMap.yaml # Alloy configuration
│ └── shared-secrets.yaml # Secrets shared between runner components
│ └── _helpers.tpl # Helpers funtions for Helm Chart templates rendering
└── charts/ # Dependencies (subcharts)
├── dagger-helm/ # Container runtime for workflows
├── kube-state-metrics/ # Cluster-level metrics
└── alloy/ # Grafana Alloy telemetry collector
Prerequisites
- Kubernetes 1.19+
- Helm 3.0+
- PV provisioner support in the underlying infrastructure
- NATS credentials for messaging
- Registry TLS certificates (if using private registry)
Permissions
Components
Agent Manager
Repository: kubiya-agent-manager
The Agent Manager handles lifecycle management of Kubiya agents within the cluster.
Kubiya Operator
Repository: kubiya-operator
The Kubiya Operator manages operational aspects and configuration of the runner components.
Tool Manager
The Kubiya Tool Manager is a high-performance, container-native utility designed for declarative management and execution of agent tools across diverse computing environments. It provides a scalable, stateless architecture for tool orchestration, supporting both local development and enterprise-scale Kubernetes deployments.
Full documentation is available in project repository.
- Executes tools within the cluster
- Integrates with Dagger for container runtime
- Includes SDK server for tool execution
Workflow Engine
The Workflow Engine is responsible for managing and executing workflows in the Kubiya Runner. It provides a scalable, containerized environment for workflow execution and orchestration.
- Manages workflow execution and orchestration
- Communicates with the Tool Manager for tool execution
- Provides workflow status and metrics
Image Updater
TBD, (depricated approach)
- Checks for updates of latest stable image versions via CronJob (hourly by default).
- Automatic updates for runner components (agent-manager, tool-manager, sdk-server) from stable release JSON file hosted in [S3 bucket](https://kubiya-cli.s3.amazonaws.com/stable/kubiya_versions.json).
Dependencies & Compatibility Matrix
This chart (as of version 0.8.0) is tested to be compatible with the following versions of container images and Helm dependencies.
Helm Dependencies
| Chart | Version | App Version |
|---|---|---|
| dagger-helm | 0.4.1 | 0.11.6 |
| kube-state-metrics | 5.27.0 | 2.14.0 |
| alloy | 0.10.1 | v1.5.1 |
Container Images
| Component | Image | Version/Tag |
|---|---|---|
| Agent Manager | ghcr.io/kubiyabot/agent-manager | v0.4.3 |
| Kubiya Operator | ghcr.io/kubiyabot/kubiya-operator | runner_v2 |
| Tool Manager | ghcr.io/kubiyabot/tool-manager | 0.5.4 |
| SDK Server | ghcr.io/kubiyabot/sdk-py | v1.20.0 |
| Workflow Engine | ghcr.io/kubiyabot/workflow-engine | v1.46.1 |
| Image Updater | ghcr.io/kubiyabot/kubernetes | 1.32.0 |
| Dagger Engine | ghcr.io/kubiyabot/kubiya-registry | v0.2.1 |
| Kube State Metrics | registry.k8s.io/kube-state-metrics/kube-state-metrics | v2.14.0 |
| Grafana Alloy | grafana/alloy | v1.5.1 |
Monitoring & Telemetry
The kubiya-runner uses Grafana Alloy for metrics collection from multiple customer runner deployments.
Alloy scrapes data from a set of targets (pods, services, etc.) which expose metrics on an endpoint (usually /metrics), processes them (filters, adds runner deployment labels, etc.) and pushes via Prometheus native remote_writes into Azure Managed Prometheus.
Later kubiya-runner chart releases expect to use Alloy for other types of telemetry data collection (such as logs and traces). Alloy also fully compatible with OpenTelemetry and can be configured to listen/send messages in OTEL format if needed, has a long list of vendor platforms and message formats compatibility and a rich set of data processing modules.
Security
Both Alloy and kube-state-metrics has limited RBAC permissions and configured to collect only data from same kubernetes namespace where kubiya-runner is deployed (kubiya by default).
Alloy runs as non-root user.
Architecture
graph LR
H[alloy-self-metrics]
A[kube-state-metrics]
B[blackbox-exporter]
C[tool-manager exporter]
D[agent-manager exporter]
E[grafana alloy]
F[azure managed prometheus]
G[grafana dashboards]
W[workflow-engine exporter (under dev)]
subgraph kubiya-runner
A ---> E
B ---> E
C ---> E
D ---> E
H ---> E
W ---> E
E
end
E ---> F
F ---> G
Grafana Alloy Configuration
- Resource Management
Default resource limits for alloy
yaml resources: limits: cpu: 1 memory: 1Gi requests: cpu: 100m memory: 128Mi
alloy resource estimation guidelines available at: https://grafana.com/docs/alloy/latest/introduction/estimate-resource-usage/
- Resources & Data Collection Configuration
To minimizes resource usage and cost on both the client and server sides, telemetry collection strategy focuses on deploying and configuring components to capture only the metrics essential for current business and operational goals. This pattern is highly recommended keeping when contributing.
Alloy is configured with a single scrape interval, collecting metrics from all targets once every 60 seconds. As a result, 60 seconds is the maximum precision for all metric visualizations and alerting.
If this level of precision is insufficient, the scrape interval can be adjusted—either increased or decreased—to balance resource impact. These adjustments can be applied globally or to specific targets via values.yaml:
alloy:
scrapeIntervals:
default: 60s
runnerExporters: 60s
alloyExporter: 60s
blackboxExporter: 60s
kubeStateMetrics: 60s
cadvisor: 60s (disabled by default)
Azure Prometheus Integration
Required set of environment variables to be set for Azure Managed Prometheus remote writes support:
AZURE_REMOTE_WRITE_URL: Azure Prometheus endpointAZURE_CLIENT_ID: Azure service principal client IDAZURE_CLIENT_SECRET: Azure service principal secretAZURE_TOKEN_URL: Azure OAuth token URL
These variables confurable via values.yaml alloy.alloy.extraEnv)
Grafana Dashboards
Grafana dashboards JSONs available in the kubiya-runner and located in helm-charts/charts/kubiya-runner/_grafana/dashboards/, alerts as code can be found under helm-charts/charts/kubiya-runner/_grafana/alerts
Single View Runners Cumulative Health Score
Dashboard monitors health using a composite scoring system. Each runner's cumulative health score is calculated as the unweighted average of five key health signals, each normalized to a 0-100% scale:
(
+ Tool-Manager HTTP Success Rate (%)
+ Agent-Manager HTTP Success Rate (%)
+ Pod Ready Status (%)
+ Pod Restart Stability (%)
+ Probe Success Rate (%)
) / 5
Individual Health Signal Formulas and PromQL Functions
-
Tool-Manager HTTP Success Rate
(sum by (organization, runner) (rate(response_status{status=~"2..", app="tool-manager"}[5m])) / sum by (organization, runner) (rate(http_requests_total{app="tool-manager"}[5m]))) * 100rate(): Calculates the per-second rate of successful responses over 5-minute windowsum by: Aggregates metrics by organization and runner- Purpose: Measures percentage of successful (2xx) HTTP responses from the Tool Manager
-
Agent-Manager HTTP Success Rate
(sum by (organization, runner) (rate(agent_manager_http_requests_total{status=~"2.."}[5m])) / sum by (organization, runner) (rate(agent_manager_http_requests_total[5m]))) * 100- Similar functions as Tool-Manager rate, applied to Agent Manager metrics
- Purpose: Measures percentage of successful HTTP responses from the Agent Manager
-
Pod Ready Status
(sum by (organization, runner) (avg_over_time(kube_pod_status_ready{condition="true"}[5m]) * on (pod) group_left(label_app_kubernetes_io_kubiya_runner_component) kube_pod_labels{label_app_kubernetes_io_kubiya_runner_component!=""}) / count by (organization, runner) (kube_pod_labels{label_app_kubernetes_io_kubiya_runner_component!=""})) * 100avg_over_time(): Smooths pod ready status over 5 minutes* on (pod) group_left(): Joins metrics on pod label to include component information- Purpose: Calculates percentage of runner pods in "ready" state
-
Pod Restart Stability
(1 - clamp_max(sum by (organization, runner)(rate(kube_pod_container_status_restarts_total[5m]) * on (pod) group_left(label_app_kubernetes_io_kubiya_runner_component) kube_pod_labels{label_app_kubernetes_io_kubiya_runner_component!=""}) * 300 / 1.0, 1)) * 100clamp_max(): Caps the maximum value at 1* 300 / 1.0: Normalizes to consider 1 restart per 5 minutes (300s) as problematic- Purpose: Penalizes container restarts (0 restarts = 100%, 1+ restart per 5 minutes = 0%)
-
Probe Success Rate
avg by (organization, runner) (avg_over_time(probe_success{exporter="blackbox-exporter"}[5m])) * 100avg by: Calculates average success rate by organization and runner- Purpose: Measures percentage of successful health endpoint probes from blackbox exporter
Health Thresholds
These thresholds are base and expected to be tuned in short term,
| Metric | Healthy (Green) | Warning (Yellow) | Degraded (Orange) | Down (Red) |
|---|---|---|---|---|
| Cumulative Score | 100% | 99-99.9% | 90-98.9% | 0-89.9% |
Alerts
The dashboard is connected to an alerting rule that triggers when any runner's cumulative health score falls below 100% for more than 5 minutes. The alert includes:
- Source: Panel ID 17 from the All Runners Health State dashboard
- Description: "C
Deploy kubiya-runner with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has kubiya-runner 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 chartkubiya-runner is pinned at v0.9.4 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