gcp

package
v0.10.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 18, 2024 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BackupProviderConfigGCP

type BackupProviderConfigGCP struct {
	BucketName     string
	BucketLocation string
	BackupName     string
	ObjectPrefix   string
	ObjectsToKeep  int64
	ProjectID      string
	FS             afero.Fs
	ClientOpts     []option.ClientOption
}

BackupProviderConfigGCP provides configuration for the BackupProviderGCP

type BackupProviderGCP

type BackupProviderGCP struct {
	// contains filtered or unexported fields
}

BackupProviderGCP implements the backup provider interface for GCP

func New

New returns a GCP backup provider

func (*BackupProviderGCP) CleanupBackups

func (b *BackupProviderGCP) CleanupBackups(_ context.Context) error

CleanupBackups cleans up backups according to the given backup cleanup policy at the backup provider

func (*BackupProviderGCP) DownloadBackup

func (b *BackupProviderGCP) DownloadBackup(ctx context.Context, version *providers.BackupVersion) error

DownloadBackup downloads the given backup version to the restoration folder

func (*BackupProviderGCP) EnsureBackupBucket

func (b *BackupProviderGCP) EnsureBackupBucket(ctx context.Context) error

EnsureBackupBucket ensures a backup bucket at the backup provider

func (*BackupProviderGCP) GetNextBackupName

func (b *BackupProviderGCP) GetNextBackupName(_ context.Context) string

GetNextBackupName returns a name for the next backup archive that is going to be uploaded

func (*BackupProviderGCP) ListBackups

ListBackups lists the available backups of the backup provider

func (*BackupProviderGCP) UploadBackup

func (b *BackupProviderGCP) UploadBackup(ctx context.Context, sourcePath string) error

UploadBackup uploads a backup to the backup provider

type BackupVersionsGCP

type BackupVersionsGCP struct {
	// contains filtered or unexported fields
}

func (BackupVersionsGCP) Get

func (BackupVersionsGCP) Latest

func (BackupVersionsGCP) List

func (BackupVersionsGCP) Sort

func (b BackupVersionsGCP) Sort(versions []*providers.BackupVersion, asc bool)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL