credentials

package
v0.0.0-...-9a1ada9 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DetectDefaultStore

func DetectDefaultStore(c *cliconfig.ConfigFile)

DetectDefaultStore sets the default credentials store if the host includes the default store helper program.

Types

type Store

type Store interface {
	// Erase removes credentials from the store for a given server.
	Erase(serverAddress string) error
	// Get retrieves credentials from the store for a given server.
	Get(serverAddress string) (types.AuthConfig, error)
	// GetAll retrieves all the credentials from the store.
	GetAll() (map[string]types.AuthConfig, error)
	// Store saves credentials in the store.
	Store(authConfig types.AuthConfig) error
}

Store is the interface that any credentials store must implement.

func NewFileStore

func NewFileStore(file *cliconfig.ConfigFile) Store

NewFileStore creates a new file credentials store.

func NewNativeStore

func NewNativeStore(file *cliconfig.ConfigFile) Store

NewNativeStore creates a new native store that uses a remote helper program to manage credentials.

Jump to

Keyboard shortcuts

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