backup

package
v1.2.6 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	S3 *storage.S3
}

Manager type

func NewManager

func NewManager(S3 *storage.S3) *Manager

NewManager create a new backup manager

func (*Manager) BackupDirectory added in v0.1.4

func (m *Manager) BackupDirectory(directory, archive string) error

BackupDirectory creates a backup of any directory directory must be absolute path like /etc/app and archive same /etc/app.tar.gz"

func (*Manager) BackupMySQL added in v0.1.5

func (m *Manager) BackupMySQL(mysql *MySQL, archive string) error

BackupMySQL backup and compress the mysql dump file

func (*Manager) ProcessBackup

func (m *Manager) ProcessBackup(message module.BackupMessage) error

ProcessBackup process a backup request

func (*Manager) RestoreDirectory added in v0.1.4

func (m *Manager) RestoreDirectory(archive, destination string) error

RestoreDirectory uncompress .tar.gz archive to the root path /

type MySQL added in v0.1.5

type MySQL struct {
	Host         string
	Port         string
	Username     string
	Password     string
	AllDatabases bool
	Database     string
	Table        string
	Options      string
	OutputFile   string
}

MySQL type

func (*MySQL) DumpOptions added in v0.1.5

func (m *MySQL) DumpOptions() string

DumpOptions dump backup options

Jump to

Keyboard shortcuts

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