Files
cozystack/examples/backups/redis/backupclass.yaml
T
Andrey Kolkov ac79c3757b test(backups): self-contained Redis backup round-trip e2e
The Redis driver shipped no round-trip backup/restore e2e, unlike its
ClickHouse, MariaDB and RabbitMQ siblings, so the backup to S3 and restore
data path had no automated coverage. The existing demo backed up through the
platform cozy-default BackupClass, whose endpoint is the shared system
bucket; in the e2e environment that bucket's advertised external address is
not routable, so a cozy-default round-trip cannot run there.

Rework examples/backups/redis to provision its OWN Bucket + Redis strategy +
BackupClass (mirroring the MariaDB and RabbitMQ demos), projecting the
bucket's keys and the seaweedfs CA into the Secrets the strategy references
and honouring an S3_ENDPOINT override so the backup Pod targets the
in-cluster seaweedfs. Add a redis-2-backup-roundtrip Chainsaw test that
drives run-all.sh in tenant-root and asserts the sentinel round-trips
through object storage in place and into a copy.

Signed-off-by: Andrey Kolkov <androndo@gmail.com>
Assisted-by: LLM
2026-09-08 17:57:06 +04:00

19 lines
590 B
YAML

# Maps Kind=Redis to this demo's Redis strategy. BackupClass is cluster-scoped,
# so a single instance covers every namespace. Named redis-default so it does
# not collide with the platform cozy-default class, which routes Redis to the
# shipped cozy-default-redis strategy.
---
apiVersion: backups.cozystack.io/v1alpha1
kind: BackupClass
metadata:
name: redis-default
spec:
strategies:
- application:
apiGroup: apps.cozystack.io
kind: Redis
strategyRef:
apiGroup: strategy.backups.cozystack.io
kind: Redis
name: redis-strategy-default