Skip to content

Setting up Telemetry

Several of Kubescape's in-cluster components implement telemetry data using OpenTelemetry (otel).\ You can optionally install an Otel collector to your cluster to aggregate all metrics and send them to your own tracing tool.

You simply have to fill in this information before installing kubescape operator:\ you need to edit the property below at values.yaml OR using --set while installing the helm chart\

configurations:
  otelUrl: # Default is empty. Add your Open Telemetry URL here.

..
..
..

otelCollector:
  name: otel-collector
  endpoint: 
    insecure: true # configurable
    headers:
      uptrace-dsn: "" # configurable

If you don't have an otel distribution, we suggest you try either Uptrace or SigNoz as they are free, opensource and can be quickly deployed using docker-compose.

Host metrics collection

The OpenTelemetry collector is configured with the hostmetrics receiver to collect CPU and memory utilization metrics.

Note that the hostmetrics receiver is disabled by default. If you wish to enable it, simply install the operator with --set otelCollector.hostmetrics.enabled=true

Example: exporting to uptrace running inside docker-compose

flowchart LR
    subgraph kubernetes
    A(kubescape) --> B(otel collector)
    D(operator) --> B
    E(host-scanner) --> B
    F(kubevuln) --> B
    end
    subgraph docker-compose
    B --> C(uptrace)
    end
  1. Download the example using Git:
git clone https://github.com/uptrace/uptrace.git
cd uptrace/example/docker
  1. Start the services using Docker:
docker-compose pull
docker-compose up -d
  1. Make sure Uptrace is running:
docker-compose logs uptrace
  1. Follow the instructions above, add the OTEL collector configuration and install the operator as follows:
--set configurations.otelUrl=<collector host>:14317 --set otelCollector.endpoint.insecure=false
  1. Open Uptrace UI at http://localhost:14318/overview/2