Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Stores map[string]func(opts ...Option) (Store, error) = map[string]func(opts ...Option) (Store, error){ "file": NewFileStore, "s3": NewS3Store, }
Functions ¶
Types ¶
type Option ¶
type Option func(o *Options)
func WithAWSAccessKey ¶
func WithAWSSecretAccessKey ¶
func WithDirectory ¶
func WithPathStyleAddressing ¶
func WithS3Endpoint ¶
type Options ¶
type Options struct { // Directory is the directory name for file store // For s3 Directory is used as Bucket name Directory string // S3Endpoint is used for custom s3 hosted server // or other aws s3 compatible solutions. // eg - for local minio server without https will be // http://localhost:9000 S3Endpoint string // S3 differentiates between "virtual hosted bucket addressing" and "path-style addressing". // Example URL for the virtual host style: http://BUCKET.s3.amazonaws.com/KEY. // Example UL for the path style: http://s3.amazonaws.com/BUCKET/KEY. // Most S3-compatible servers work with both styles, // but some work only with the virtual host style (e.g. Alibaba Cloud Object Storage Service (OSS)) // and some work only with the path style (especially self-hosted services like a Minio server running on localhost). // Optional (false by default). UsePathStyleAddressing bool // AWS access key ID (part of the credentials). // Optional (read from shared credentials file or environment variable if not set). // Environment variable: "AWS_ACCESS_KEY_ID". AWSaccessKeyID string // AWS secret access key (part of the credentials). // Optional (read from shared credentials file or environment variable if not set). // Environment variable: "AWS_SECRET_ACCESS_KEY". AWSsecretAccessKey string }
Click to show internal directories.
Click to hide internal directories.