cron

package
v2.4.2-rc2+incompatible Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2019 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BackupJobTemplate *template.Template

Functions

This section is empty.

Types

type BackBaseBackupJob

type BackBaseBackupJob struct {
	Name            string
	PvcName         string
	CCPImagePrefix  string
	CCPImageTag     string
	BackupHost      string
	BackupUser      string
	BackupPass      string
	BackupPort      string
	SecurityContext SecurityContext
	Secret          string
	Namespace       string
	// contains filtered or unexported fields
}

func (BackBaseBackupJob) Run

func (b BackBaseBackupJob) Run()

type BackRestBackupJob

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

func (BackRestBackupJob) Run

func (b BackRestBackupJob) Run()

type Cron

type Cron struct {
	CronClient *cv2.Cron
	// contains filtered or unexported fields
}

func New

func New(label, namespace string, client *kubeapi.KubeAPI) *Cron

func (*Cron) AddJobs

func (c *Cron) AddJobs() error

func (*Cron) DeleteJobs

func (c *Cron) DeleteJobs() error

type Options

type Options struct {
	Name  string `json:"name,omitempty"`
	Value string `json:"value,omitempty"`
}

type PGBackRest

type PGBackRest struct {
	Deployment string    `json:"deployment"`
	Label      string    `json:"label"`
	Container  string    `json:"container"`
	Type       string    `json:"type"`
	Options    []Options `json:"options"`
}

type PGBaseBackup

type PGBaseBackup struct {
	BackupHost      string `json:"backupHost"`
	BackupPass      string `json:"backupPass"`
	BackupPort      string `json:"backupPort"`
	BackupUser      string `json:"backupUser"`
	BackupVolume    string `json:"backupVolume"`
	ImagePrefix     string `json:"imagePrefix"`
	ImageTag        string `json:"imageTag"`
	Secret          string `json:"secret"`
	SecurityContext `json:"securityContext"`
}

type ScheduleTemplate

type ScheduleTemplate struct {
	Version      string    `json:"version"`
	Name         string    `json:"name"`
	Created      time.Time `json:"created"`
	Schedule     string    `json:"schedule"`
	Namespace    string    `json:"namespace"`
	Type         string    `json:"type"`
	PGBackRest   `json:"pgbackrest,omitempty"`
	PGBaseBackup `json:"pgbasebackup,omitempty"`
}

func (*ScheduleTemplate) NewBackBaseBackupSchedule

func (s *ScheduleTemplate) NewBackBaseBackupSchedule(client *kubeapi.KubeAPI) BackBaseBackupJob

func (*ScheduleTemplate) NewBackRestSchedule

func (s *ScheduleTemplate) NewBackRestSchedule(stanza string, client *kubeapi.KubeAPI) BackRestBackupJob

type SecurityContext

type SecurityContext struct {
	FSGroup            int   `json:"fsGroup,omitempty"`
	SupplementalGroups []int `json:"supplementalGroups,omitempty"`
}

Jump to

Keyboard shortcuts

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