miniox

package
v1.9.4 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2025 License: MIT Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrClientIsNotInitialized = errors.New("client is not initialized")
	ErrMinioOffline           = errors.New("minio offline")
)

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(logger log.Logger) *Client

func (*Client) Client

func (c *Client) Client() (*minio.Client, error)

func (*Client) Healthcheck added in v1.9.2

func (c *Client) Healthcheck(_ context.Context) error

func (*Client) Upgrade

func (c *Client) Upgrade(ctx context.Context, cfg Config, opts ...Option) error

type Config

type Config struct {
	Endpoint          string       `schema:"Endpoint minio кластера без указания схемы" validate:"required"`
	Credentials       *Credentials `schema:"Данные для авторизации,secret"`
	Secure            bool         `schema:"Использовать https или нет"`
	UploadFileThreads uint         `schema:"Максимальное количество потоков для загрузки файла"`
}

type Credentials

type Credentials struct {
	Id     string `schema:"Логин,secret"`
	Secret string `schema:"Пароль,secret"`
	Token  string `schema:"Токен,secret"`
}

type Option

type Option func(opt *minio.Options)

func OptionsFromConfig

func OptionsFromConfig(cfg Config) []Option

func WithCredentials

func WithCredentials(creds *credentials.Credentials) Option

func WithSecure

func WithSecure(secure bool) Option

func WithTransport

func WithTransport(transport http.RoundTripper) Option

Jump to

Keyboard shortcuts

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