Files
cozystack/packages/system/cozystack-controller/templates/deployment.yaml
Andrei KvapilandClaude 987a74ae5a refactor(telemetry): split telemetry between operator and controller
Split telemetry collection between cozystack-operator and cozystack-controller:

cozystack-operator now collects cluster-level metrics:
- cozy_cluster_info (cozystack_version, kubernetes_version)
- cozy_nodes_count (os, kernel)
- cozy_cluster_capacity (cpu, memory, nvidia.com/* resources)
- cozy_loadbalancers_count
- cozy_pvs_count (driver, size)
- cozy_package_info (name, variant)

cozystack-controller now collects application-level metrics:
- cozy_application_count (kind) - counts HelmReleases per ApplicationDefinition

Other changes:
- Add pkg/version for build-time version injection via ldflags
- Remove --cozystack-version flag (version now embedded at build time)
- Remove bundle/oidc configuration from telemetry (replaced by package_info)
- Remove cozy_workloads_count metric (replaced by cozy_application_count)

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2026-01-19 13:52:15 +01:00

33 lines
849 B
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: cozystack-controller
labels:
app: cozystack-controller
spec:
replicas: 1
selector:
matchLabels:
app: cozystack-controller
template:
metadata:
labels:
app: cozystack-controller
spec:
serviceAccountName: cozystack-controller
containers:
- name: cozystack-controller
image: "{{ .Values.cozystackController.image }}"
args:
{{- if .Values.cozystackController.debug }}
- --zap-log-level=debug
{{- else }}
- --zap-log-level=info
{{- end }}
{{- if .Values.cozystackController.disableTelemetry }}
- --disable-telemetry
{{- end }}
{{- if eq .Values.cozystackController.cozystackAPIKind "Deployment" }}
- --reconcile-deployment
{{- end }}