From d45e8d6e6c1985c34da22cfeac1b5844c72ad7a4 Mon Sep 17 00:00:00 2001 From: Loic Devulder Date: Tue, 24 Sep 2024 15:27:16 +0200 Subject: [PATCH] ci/cli: Add etcd snapshot for downstream clusters This is needed to be able to run a migration test. Signed-off-by: Loic Devulder --- tests/assets/cluster.yaml | 4 +++- tests/e2e/backup-restore_test.go | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/assets/cluster.yaml b/tests/assets/cluster.yaml index df4091cea..16bc478c8 100644 --- a/tests/assets/cluster.yaml +++ b/tests/assets/cluster.yaml @@ -6,7 +6,9 @@ metadata: spec: rkeConfig: etcd: - disableSnapshots: true + disableSnapshots: false + snapshotRetention: 5 + snapshotScheduleCron: 0 */5 * * * machineGlobalConfig: cni: canal disable: diff --git a/tests/e2e/backup-restore_test.go b/tests/e2e/backup-restore_test.go index 62d199811..7081292f4 100644 --- a/tests/e2e/backup-restore_test.go +++ b/tests/e2e/backup-restore_test.go @@ -163,7 +163,7 @@ var _ = Describe("E2E - Test full Backup/Restore", Label("test-full-backup-resto err := tools.Sed("%BACKUP_FILE%", backupFile, restoreYaml) Expect(err).To(Not(HaveOccurred())) - // "prune" option should be set to true here + // "prune" option should be set to false in case of migration test err = tools.Sed("%PRUNE%", "false", restoreYaml) Expect(err).To(Not(HaveOccurred()))