Files
cozystack/packages/system/monitoring/tests/alerta_image_test.yaml
T
Aleksei Sviridkin b7ec3f73a1 test(monitoring): keep a non-first-party ref in the Alerta image test
A ghcr.io/cozystack/cozystack ref in a helm-unittest fixture counts as
a first-party image ref, so the image-ref enumeration contracts in
hack/promote-rewrite-tags_test.bats require its file to be declared.
The test only needs some image string to pass through cozy-lib.image,
so a placeholder registry keeps it out of the release tooling.

Assisted-by: LLM
Signed-off-by: Aleksei Sviridkin <f@lex.la>
2026-11-17 18:09:25 +01:00

41 lines
1.4 KiB
YAML

suite: alerta runs the image from values through cozy-lib.image
templates:
- templates/alerta/alerta.yaml
release:
name: monitoring
namespace: tenant-root
set:
_cluster:
issuer-name: letsencrypt-prod
solver: http01
gateway-enabled: "false"
_namespace:
host: example.org
ingress: tenant-root
tests:
- it: renders alerta.image as the container image
set:
alerta.image: registry.example.com/alerta:v9.1.0-cozystack.0@sha256:0000000000000000000000000000000000000000000000000000000000000000
documentSelector:
path: kind
value: Deployment
asserts:
- equal:
path: spec.template.spec.containers[0].image
value: registry.example.com/alerta:v9.1.0-cozystack.0@sha256:0000000000000000000000000000000000000000000000000000000000000000
- it: prefixes the image with the cluster images-registry when set
set:
_cluster.images-registry: mirror.example.com
alerta.image: registry.example.com/alerta:v9.1.0-cozystack.0@sha256:0000000000000000000000000000000000000000000000000000000000000000
documentSelector:
path: kind
value: Deployment
asserts:
- equal:
path: spec.template.spec.containers[0].image
value: mirror.example.com/registry.example.com/alerta:v9.1.0-cozystack.0@sha256:0000000000000000000000000000000000000000000000000000000000000000