config

package
v0.0.0-...-7529ad9 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2023 License: Apache-2.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 BackupFolderConfig

type BackupFolderConfig struct {
	SrcPath        string `yaml:"srcPath"`
	DestPrefix     string `yaml:"destPrefix"`
	Gzip           bool   `yaml:"gzip"`
	S3StorageClass string `yaml:"s3StorageClass"`
}

type BackupFolderConfigCollection

type BackupFolderConfigCollection []BackupFolderConfig

type Config

type Config struct {
	AWS struct {
		S3BucketName string `yaml:"s3BucketName"`
		ProfileName  string `yaml:"profileName"`
		Region       string `yaml:"region"`
	}
	Backup struct {
		DefaultS3StorageClass  string `yaml:"defaultS3StorageClass"`
		DefaultPrefixToPrepend string `yaml:"defaultPrefixToPrepend"`
		Folders                BackupFolderConfigCollection
		GlobalExcludes         []string `yaml:"globalExcludes"`
	}
}

func Read

func Read(configPath string) (*Config, error)

func (*Config) AllBackupSubDirs

func (c *Config) AllBackupSubDirs() (allBackupSubDirs []BackupFolderConfig)

func (*Config) Validate

func (c *Config) Validate() bool

Jump to

Keyboard shortcuts

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