Documentation
¶
Index ¶
- Constants
- type Input
- type Minio
- func (m Minio) GetAccessKey() string
- func (m Minio) GetBaseEndpoint() string
- func (m Minio) GetBucket() string
- func (m Minio) GetConsoleBaseURL() string
- func (m Minio) GetConsoleURL() string
- func (m Minio) GetEndpoint() string
- func (m Minio) GetRegion() string
- func (m Minio) GetSecretKey() string
- func (m Minio) Output() *Output
- type MinioFactory
- type Option
- type Output
- type Provider
- type ProviderFactory
Constants ¶
View Source
const ( DefaultImage = "minio/minio" DefaultName = "minio" DefaultBucket = "test-bucket" DefaultRegion = "us-east-1" DefaultHost = "minio" DefaultPort = 9000 DefaultConsolePort = 9001 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Minio ¶
type Minio struct { Host string `toml:"host"` Port int `toml:"port"` ConsolePort int `toml:"console_port"` AccessKey string `toml:"access_key"` SecretKey string `toml:"secret_key"` Bucket string `toml:"bucket"` Region string `toml:"region"` }
func DefaultMinio ¶
func DefaultMinio() *Minio
func (Minio) GetAccessKey ¶
func (Minio) GetBaseEndpoint ¶
func (Minio) GetConsoleBaseURL ¶
func (Minio) GetConsoleURL ¶
func (Minio) GetEndpoint ¶
func (Minio) GetSecretKey ¶
type MinioFactory ¶
type MinioFactory struct{}
type Option ¶
type Option func(*Minio)
func WithAccessKey ¶
func WithConsolePort ¶
func WithSecretKey ¶
type Output ¶
type Output struct { SecretKey string `toml:"secret_key"` AccessKey string `toml:"access_key"` Bucket string `toml:"bucket"` ConsoleURL string `toml:"console_url"` ConsoleBaseURL string `toml:"console_base_url"` Endpoint string `toml:"endpoint"` BaseEndpoint string `toml:"base_endpoint"` Region string `toml:"region"` UseCache bool `toml:"use_cache"` }
type Provider ¶
type Provider interface { GetEndpoint() string GetBaseEndpoint() string GetConsoleURL() string GetConsoleBaseURL() string GetSecretKey() string GetAccessKey() string GetBucket() string GetRegion() string Output() *Output }
Provider is the interface that wraps S3 interaction methods.
type ProviderFactory ¶
type ProviderFactory interface { New(...Option) (Provider, error) NewFrom(*Input) (*Output, error) }
ProviderFactory is the interface that standardizes S3 providers constructors.
func NewMinioFactory ¶
func NewMinioFactory() ProviderFactory
Click to show internal directories.
Click to hide internal directories.