Versions in this module Expand all Collapse all v1 v1.0.0 Jun 8, 2024 Changes in this version + type GCP struct + ApiKey string + BucketName string + Host string + ProjectID string + func (gcp *GCP) Get(ctx context.Context, path string) (io.Reader, error) + func (gcp *GCP) Put(ctx context.Context, path string, object io.Reader) error + type InactiveProvider struct + ProviderName string + func (ip *InactiveProvider) Get(ctx context.Context, path string) (io.Reader, error) + func (ip *InactiveProvider) Put(ctx context.Context, path string, object io.Reader) error + type Local struct + Filepath string + func (l *Local) Get(ctx context.Context, fullpath string) (io.Reader, error) + func (l *Local) Put(ctx context.Context, fullpath string, f io.Reader) (err error) + type S3 struct + AccessKey string + Bucket string + BucketRegion string + Endpoint string + SSL bool + SecretKey string + func (s *S3) Get(ctx context.Context, path string) (io.Reader, error) + func (s *S3) Put(ctx context.Context, path string, f io.Reader) error + type SLocal struct + Filepath string + Secret string + func (l *SLocal) Get(ctx context.Context, fullpath string) (io.Reader, error) + func (l *SLocal) Put(ctx context.Context, fullpath string, f io.Reader) (err error) + type SS3 struct + AccessKey string + Bucket string + BucketRegion string + Endpoint string + SSL bool + Secret string + SecretKey string + func (s *SS3) Get(ctx context.Context, path string) (io.Reader, error) + func (s *SS3) Put(ctx context.Context, path string, f io.Reader) error + type StorageProvider interface + Get func(ctx context.Context, path string) (io.Reader, error) + Put func(ctx context.Context, path string, object io.Reader) error + func NewGCPStorage(cfg config.Getter) (StorageProvider, error) + func NewInactiveProvider(providerName string) StorageProvider + func NewLocalStorage(conf config.Getter) (StorageProvider, error) + func NewS3Storage(conf config.Getter) (StorageProvider, error) + func NewSLocalStorage(conf config.Getter) (StorageProvider, error) + func NewSS3Storage(conf config.Getter) (StorageProvider, error)