feat(platform): deploy the observability-proxy

The proxy only answers for stores that the monitoring stack runs, so it
follows monitoring-agents: on by default in the full variants and
opt-in through enabledPackages on the slim ones, where monitoring is
opt-in too. It is a stateless reader with no CRDs, so networking is its
only dependency.

Assisted-by: LLM
Signed-off-by: ZverGuy <maximbel2003@gmail.com>
This commit is contained in:
ZverGuy committed 2026-11-09 15:48:57 +07:00
1 parent 7ec648d863
commit bbdf05c6c7
4 files changed
+92

No files matched your search

@@ -0,0 +1,21 @@
---
apiVersion: cozystack.io/v1alpha1
kind: PackageSource
metadata:
name: cozystack.observability-proxy
spec:
sourceRef:
kind: OCIRepository
name: cozystack-packages
namespace: cozy-system
path: /
variants:
- name: default
dependsOn:
- cozystack.networking
components:
- name: observability-proxy
path: system/observability-proxy
install:
namespace: cozy-observability-proxy
releaseName: observability-proxy
@@ -344,6 +344,7 @@ variants and opt-in on the slim ones. */}}
{{include "cozystack.platform.package.full.default" (list "cozystack.metrics-server" $) }}
{{- $monitoringAgentsComponents := dict "monitoring-agents" (dict "values" (dict "global" (dict "target" "tenant-root"))) -}}
{{include "cozystack.platform.package.full" (list "cozystack.monitoring-agents" "default" $ $monitoringAgentsComponents) }}
{{include "cozystack.platform.package.full.default" (list "cozystack.observability-proxy" $) }}
{{include "cozystack.platform.package.full.default" (list "cozystack.goldpinger" $) }}
{{include "cozystack.platform.package.default" (list "cozystack.prometheus-operator-crds" $) }}
{{include "cozystack.platform.package.full.default" (list "cozystack.grafana-operator" $) }}
@@ -42,6 +42,7 @@ bundles:
- cozystack.monitoring
- cozystack.nats-application
- cozystack.nfs-driver
- cozystack.observability-proxy
- cozystack.openbao-application
- cozystack.opensearch-application
- cozystack.opensearch-operator
@@ -0,0 +1,69 @@
suite: observability-proxy package wiring
# The proxy reads the tenant log and metrics stores, which the full variants
# run by default and the slim ones only on request, so it follows
# monitoring-agents: on by default in the full variants, opt-in on the slim.
templates:
- templates/sources.yaml
- templates/bundles/system.yaml
release:
name: cozystack
namespace: cozy-system
tests:
- it: installs into cozy-observability-proxy once networking is up
template: templates/sources.yaml
documentSelector:
path: metadata.name
value: cozystack.observability-proxy
asserts:
- equal:
path: kind
value: PackageSource
- equal:
path: spec.variants[0].dependsOn
value:
- cozystack.networking
- equal:
path: spec.variants[0].components
value:
- name: observability-proxy
path: system/observability-proxy
install:
namespace: cozy-observability-proxy
releaseName: observability-proxy
- it: emits the package on a full variant
template: templates/bundles/system.yaml
values:
- ../values-isp-full.yaml
asserts:
- containsDocument:
apiVersion: cozystack.io/v1alpha1
kind: Package
name: cozystack.observability-proxy
any: true
- it: leaves the package out of a slim variant by default
template: templates/bundles/system.yaml
values:
- ../values-isp-slim.yaml
asserts:
- containsDocument:
apiVersion: cozystack.io/v1alpha1
kind: Package
name: cozystack.observability-proxy
any: true
not: true
- it: emits the package on a slim variant that lists it in enabledPackages
template: templates/bundles/system.yaml
values:
- ../values-isp-slim.yaml
set:
bundles.enabledPackages:
- cozystack.observability-proxy
asserts:
- containsDocument:
apiVersion: cozystack.io/v1alpha1
kind: Package
name: cozystack.observability-proxy
any: true