Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrMissingConfigField = errors.New("objectstore: required config field missing")
ErrMissingConfigField is returned when a required Config field is empty
View Source
var ErrUnsupportedBackend = errors.New("objectstore: unsupported backend")
ErrUnsupportedBackend is returned when no registered backend can be found matching Config.Backend
Functions ¶
Types ¶
type AzureCredentials ¶
type AzureCredentials struct {
}
AzureCredentials carries resolved Azure credentials.
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client wraps a *blob.Bucket from gocloud.dev/blob plus labkit's lifecycle, observability hooks, and config metadata. Implements app.Component.
func NewWithConfig ¶
type Config ¶
type Config struct {
// Identity. Defaults: Name="objectstore", Namespace="gitlab",
// Subsystem="objectstore".
Name string
Namespace string
Subsystem string
// Backend selects which SDK + gocloud opener to use. Required.
Backend Backend
// Bucket name (S3/GCS) or container (Azure). Required.
Bucket string
// Region (S3 only). Required for AWS S3; informational for
// S3-compatibles when Endpoint is set.
Region string
// Endpoint (S3-compatibles only). Empty for AWS S3.
Endpoint string
// PathStyle forces path-style addressing (S3-compatibles).
PathStyle bool
// Per-backend credential structs. Only one is honoured per Backend;
// the others are ignored. nil = use the SDK's default credential
// chain (IRSA / Workload Identity / Managed Identity).
S3Credentials *S3Credentials
GCSCredentials *GCSCredentials
AzureCredentials *AzureCredentials
}
type GCSCredentials ¶
type GCSCredentials struct {
}
GCSCredentials carries resolved GCS credentials.
type S3Credentials ¶
type S3Credentials struct {
AccessKeyID string
SecretAccessKey string
SessionToken string // optional — STS / temporary credentials
}
S3Credentials carries resolved S3 credentials.
Click to show internal directories.
Click to hide internal directories.