Import backup repository for database services

You must be a Platform Administrator (PA) to perform the steps in this section to import backup repositories for database services. You must do this for each Organization you want to restore DBClusters in.

Import backup repository DBS

  1. On the system cluster of the target gdcloud CLI instance, create a B4GDC Backup Repository resource which points to the same bucket used to store DBS backups in the sources gdcloud CLI instance:

      cat << EOF > backup_repo_plan.yaml
      apiVersion: backup.gdc.goog/v1
      kind: BackupRepository
      metadata:
        name: dbs-backup-repository
      spec:
        secretReference:
          namespace: dbs-dr
          name: secret
        endpoint: ENDPOINT
        type: S3
        s3Options:
          bucket: ORGNAME-dbs-bucket
          region: REGION
          forcePathStyle: true
        importPolicy: ReadWrite
      EOF
      kubectl apply -f backup_repo_plan.yaml
    
  2. Verify backups are successfully imported to the Org admin cluster of the target gdcloud CLI instance:

    kubectl get backups.gdc.goog -n dbs-dr
    

    Successful backups are imported and have a Succeeded state.