From 6cbb92429cddad0dfddc2131fa606c4d52d9aab9 Mon Sep 17 00:00:00 2001 From: Michal Kralik Date: Thu, 4 Jan 2024 12:04:52 +0100 Subject: [PATCH 1/3] EVEREST-739: fix panic for initial PG backup --- controllers/databaseclusterbackup_controller.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/controllers/databaseclusterbackup_controller.go b/controllers/databaseclusterbackup_controller.go index f83792507..05d62b5ff 100644 --- a/controllers/databaseclusterbackup_controller.go +++ b/controllers/databaseclusterbackup_controller.go @@ -273,6 +273,12 @@ func (r *DatabaseClusterBackupReconciler) tryCreatePG(ctx context.Context, obj c return err } + // We want to ignore backups that are done to the hardcoded PVC-based repo1. + // This repo only exists to allow users to spin up a PG cluster without specifying a backup storage. Therefore, we don't want to allow users to restore from these backups so shouldn't create a DBB CR from repo1. + if pgBackup.Spec.RepoName == "repo1" { + return nil + } + backup := &everestv1alpha1.DatabaseClusterBackup{ ObjectMeta: metav1.ObjectMeta{ Name: namespacedName.Name, From 3c907bd957b16d3ce8d891037ce812dfab032387 Mon Sep 17 00:00:00 2001 From: Michal Kralik Date: Thu, 4 Jan 2024 12:17:42 +0100 Subject: [PATCH 2/3] Linters --- controllers/databaseclusterbackup_controller.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/controllers/databaseclusterbackup_controller.go b/controllers/databaseclusterbackup_controller.go index 05d62b5ff..193aaf3a5 100644 --- a/controllers/databaseclusterbackup_controller.go +++ b/controllers/databaseclusterbackup_controller.go @@ -274,7 +274,8 @@ func (r *DatabaseClusterBackupReconciler) tryCreatePG(ctx context.Context, obj c } // We want to ignore backups that are done to the hardcoded PVC-based repo1. - // This repo only exists to allow users to spin up a PG cluster without specifying a backup storage. Therefore, we don't want to allow users to restore from these backups so shouldn't create a DBB CR from repo1. + // This repo only exists to allow users to spin up a PG cluster without specifying a backup storage. + // Therefore, we don't want to allow users to restore from these backups so shouldn't create a DBB CR from repo1. if pgBackup.Spec.RepoName == "repo1" { return nil } From aaedf6599c5876273e24f49830ee8f8588696105 Mon Sep 17 00:00:00 2001 From: Michal Kralik Date: Fri, 5 Jan 2024 12:58:01 +0100 Subject: [PATCH 3/3] Increase resources --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4e78b2d08..ea505fd00 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -113,7 +113,7 @@ jobs: - name: Scale up cluster run: | - eksctl scale nodegroup --cluster="$CLUSTER_NAME" --nodes=5 "$NODEPOOL_NAME" --wait + eksctl scale nodegroup --cluster="$CLUSTER_NAME" --nodes=10 "$NODEPOOL_NAME" --wait env: CLUSTER_NAME: "dbaas-ci-20221005" NODEPOOL_NAME: "terraform-node-dbaas-ci-20221005"