daemon

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 19, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run()

Types

type AppCfg

type AppCfg struct {
	Logger config.Logger `json:"logger" yaml:"logger" env-prefix:"LOGGER_"`
	S3     config.S3     `json:"s3" yaml:"s3" env-prefix:"S3_"`
	Dump   struct {
		Enabled  bool            `json:"enabled" yaml:"enabled" env:"ENABLED" env-default:"true"`
		Postgres config.Postgres `json:"postgres" yaml:"postgres" env-prefix:"POSTGRES_"`
		Cron
		Timeout   time.Duration `json:"timeout" yaml:"timeout" env:"TIMEOUT" env-default:"4s"`
		GPG       `json:"gpg" yaml:"gpg" env-prefix:"GPG_"`
		Rotate    time.Duration `json:"rotate" yaml:"rotate" env:"ROTATE"`
		ExtraArgs []string      `json:"extraArgs" yaml:"extraArgs" env:"EXTRA_ARGS" env-default:""`
	} `json:"dump" yaml:"dump" env-prefix:"DUMP_"`
	Restore struct {
		Enabled  bool            `json:"enabled" yaml:"enabled" env:"ENABLED" env-default:"false"`
		Postgres config.Postgres `json:"postgres" yaml:"postgres" env-prefix:"POSTGRES_"`
		Cron
		Timeout   time.Duration `json:"timeout" yaml:"timeout" env:"TIMEOUT" env-default:"4s"`
		GPG       `json:"gpg" yaml:"gpg" env-prefix:"GPG_"`
		ExtraArgs []string `json:"extraArgs" yaml:"extraArgs" env:"EXTRA_ARGS" env-default:""`
	} `json:"restore" yaml:"restore" env-prefix:"RESTORE_"`
}

type Cron

type Cron struct {
	Interval           time.Duration `json:"interval" yaml:"interval" env:"INTERVAL" env-default:"1h"`
	Crontab            string        `json:"crontab" yaml:"crontab" env:"CRONTAB" env-default:""`
	CrontabWithSeconds bool          `json:"crontabWithSeconds" yaml:"crontabWithSeconds" env:"CRONTAB_WITH_SECONDS" env-default:"false"`
}

type GPG

type GPG struct {
	Passphrase string `json:"passphrase" yaml:"passphrase" env:"PASSPHRASE" env-default:""`
}

Jump to

Keyboard shortcuts

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