configCustom

package
Version: v1.7.2 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrorAwsError errors.CodeError = iota + errors.MinPkgAws + 20
	ErrorConfigValidator
	ErrorConfigJsonUnmarshall
	ErrorEndpointInvalid
	ErrorRegionInvalid
	ErrorRegionEndpointNotFound
	ErrorCredentialsInvalid
)

Variables

This section is empty.

Functions

func GetConfigModel

func GetConfigModel() interface{}

func IsErrorInit

func IsErrorInit() bool

func NewConfig

func NewConfig(bucket, accessKey, secretKey string, endpoint *url.URL, region string) libaws.Config

func NewConfigJsonUnmashal

func NewConfigJsonUnmashal(p []byte) (libaws.Config, errors.Error)

Types

type Model added in v1.3.2

type Model struct {
	Region    string `mapstructure:"region" json:"region" yaml:"region" toml:"region" validate:"required,hostname"`
	Endpoint  string `mapstructure:"endpoint" json:"endpoint" yaml:"endpoint" toml:"endpoint" validate:"required,url"`
	AccessKey string `mapstructure:"accesskey" json:"accesskey" yaml:"accesskey" toml:"accesskey" validate:"required,printascii"`
	SecretKey string `mapstructure:"secretkey" json:"secretkey" yaml:"secretkey" toml:"secretkey" validate:"required,printascii"`
	Bucket    string `mapstructure:"bucket" json:"bucket" yaml:"bucket" toml:"bucket" validate:"omitempty,hostname"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL