fs

package
v0.0.0-...-f12052e Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2023 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidName = errors.New("invalid name")

Functions

func Bucket

func Bucket(ctx context.Context, client *minio.Client, bucket string) error

func Generate

func Generate(homeID string, name string) string

Generate filename for given photo of the given home.

func New

func New(cfg Config) (*minio.Client, error)

New create a connection to minio to use as a file storage.

func Parse

func Parse(name string) (string, string, error)

Parse given filename to its home and photo name.

Types

type Config

type Config struct {
	Endpoint  string `koanf:"endpoint"`
	AccessKey string `koanf:"access_key"`
	SecretKey string `koanf:"secret_key"`
	UseSSL    bool   `koanf:"use_ssl"`
}

Jump to

Keyboard shortcuts

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