Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EVEREST-739: fix panic for initial PG backup #235

Merged
merged 4 commits into from
Jan 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
7 changes: 7 additions & 0 deletions controllers/databaseclusterbackup_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,13 @@ 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,
Expand Down
Loading