auth

package
v0.12.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCredentialsConfigNotSet = errors.New("credentials store config was not set up")

ErrorCodeCredentialsConfigNotSet indicates the credentials store config was not set up

Functions

func LoadConfig

func LoadConfig() (*config.Config, error)

LoadConfig loads the configuration from the config file

Types

type CredentialStore

type CredentialStore interface {
	// Store saves credentials into the store
	Store(serverAddress string, credsConf auth.Credential) error
	// Erase removes credentials from the store for the given server
	Erase(serverAddress string) error
	// Get retrieves credentials from the store for the given server
	Get(serverAddress string) (auth.Credential, error)
}

CredentialStore is the interface that any credentials store must implement.

func GetCredentialsStore

func GetCredentialsStore(registryHostname string) (CredentialStore, error)

GetCredentialsStore returns a new credentials store from the settings in the configuration file

Jump to

Keyboard shortcuts

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