This page contains instructions for how to restore a Harbor instance backup in Google Distributed Cloud (GDC) air-gapped.
Restores require an existing backup to function. The restore uses the specified backup data for the restoration. A restore only supports restoring a Harbor instance that has the same reference as the backup. The original Harbor instance must be deleted before restoration starts.
Before you begin
To create a restore, you must have access to the following:
The necessary identity and access roles:
- Harbor Instance Admin: has full access to manage Harbor instances in a project. Ask your Organization IAM Admin to grant you the Harbor Instance Admin (
harbor-instance-admin
) role. - Secret Admin: required for operating in the GDC console. Ask your Organization IAM Admin to grant you the Secret Admin (
secret-admin
) role.
- Harbor Instance Admin: has full access to manage Harbor instances in a project. Ask your Organization IAM Admin to grant you the Harbor Instance Admin (
An existing backup. You create backups from the following sources:
- GDC creates backups automatically as defined in the backup plan schedule. For more information, see Create a backup plan.
- You create manual backups. For more information, see Create a manual backup.
Create a restore
Create a restore in the GDC console or the API.
Console
- Sign in to the GDC console.
- In the navigation menu, click Backup for harbor instance.
- Click Backups.
- Click the name of the backup you want to restore.
- Click Restore a backup
API
apiVersion: artifactregistry.gdc.goog/v1
kind: HarborInstanceRestore
metadata:
name: RESTORE_NAME
namespace: INSTANCE_NAMESPACE
spec:
backupName: BACKUP_NAME
description: RESTORE_DESCRIPTION
Replace the following:
RESTORE_NAME
: the name of the restore.INSTANCE_NAMESPACE
: the namespace containing the Harbor instance. The backup plan containing the backup to restore must be in the same namespace with the Harbor instance to restore.BACKUP_NAME
: the name of the backup that the system restores.RESTORE_DESCRIPTION
: a text description of the restore being created.