config

package
v1.12.0 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database added in v1.8.0

type Database interface {
	Name() string
	PodFilters() filter.Filter
}

type DatabaseAliases added in v1.12.0

type DatabaseAliases interface {
	Aliases() []string
}

type DatabaseAnalyze added in v1.12.0

type DatabaseAnalyze interface {
	AnalyzeQuery() string
}

type DatabaseDB added in v1.12.0

type DatabaseDB interface {
	DatabaseEnvNames() kubernetes.ConfigLookups
}

type DatabaseDBDrop added in v1.12.0

type DatabaseDBDrop interface {
	DropDatabaseQuery(database string) string
}

type DatabaseDBList added in v1.12.0

type DatabaseDBList interface {
	ListDatabasesQuery() string
}

type DatabaseDisableJob added in v1.12.0

type DatabaseDisableJob interface {
	DisableJob() bool
}

type DatabaseDump added in v1.12.0

type DatabaseDump interface {
	Database
	DumpCommand(conf Dump) *command.Builder
	DatabaseFile
}

type DatabaseExec added in v1.12.0

type DatabaseExec interface {
	Database
	ExecCommand(conf Exec) *command.Builder
}

type DatabaseFile added in v1.12.0

type DatabaseFile interface {
	Formats() map[sqlformat.Format]string
}

type DatabaseFilter added in v1.12.0

type DatabaseFilter interface {
	FilterPods(ctx context.Context, client kubernetes.KubeClient, pods []v1.Pod) ([]v1.Pod, error)
}

type DatabasePassword added in v1.12.0

type DatabasePassword interface {
	PasswordEnvNames(conf Global) kubernetes.ConfigLookups
}

type DatabasePort added in v1.12.0

type DatabasePort interface {
	DefaultPort() uint16
	PortEnvNames() kubernetes.ConfigLookups
}

type DatabaseRestore added in v1.12.0

type DatabaseRestore interface {
	Database
	RestoreCommand(conf Restore, inputFormat sqlformat.Format) *command.Builder
	DatabaseFile
}

type DatabaseTables added in v1.12.0

type DatabaseTables interface {
	ListTablesQuery() string
}

type DatabaseUsername added in v1.12.0

type DatabaseUsername interface {
	UserEnvNames() kubernetes.ConfigLookups
	DefaultUser() string
}

type Dump

type Dump struct {
	Global `mapstructure:",squash"`
	Files
	Directory        string
	IfExists         bool
	Clean            bool
	NoOwner          bool
	Tables           []string
	ExcludeTable     []string
	ExcludeTableData []string
	Spinner          string
}

type Exec

type Exec struct {
	Global         `mapstructure:",squash"`
	DisableHeaders bool
	Command        string
}

type Files

type Files struct {
	Filename string `mapstructure:"name"`
	Format   sqlformat.Format
}

type Global

type Global struct {
	Kubernetes
	Client  kubernetes.KubeClient
	Dialect Database `mapstructure:"-"`

	Job    *batchv1.Job
	JobPod v1.Pod `mapstructure:"-"`
	DBPod  v1.Pod `mapstructure:"-"`

	Host       string
	Port       uint16
	Database   string
	Username   string
	Password   string
	Quiet      bool
	RemoteGzip bool `mapstructure:"remote-gzip"`
}

type Kubernetes added in v1.4.3

type Kubernetes struct {
	Kubeconfig string
	Context    string
	Namespace  string
	Client     kubernetes.KubeClient
}

type PortForward

type PortForward struct {
	Global    `mapstructure:",squash"`
	Addresses []string
	LocalPort uint16
}

type Restore

type Restore struct {
	Global `mapstructure:",squash"`
	Files
	SingleTransaction bool
	Clean             bool
	NoOwner           bool
	Force             bool
	Spinner           string
	HaltOnError       bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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