Documentation

Index

Constants

View Source
const AuthClient = "credhub_cli"
View Source
const AuthPassword = ""

Variables

This section is empty.

Functions

func ConfigDir

func ConfigDir() string

func ConfigPath

func ConfigPath() string

func ReadOrGetCaCerts

func ReadOrGetCaCerts(caCerts []string) ([]string, error)

func RemoveConfig

func RemoveConfig() error

func ValidateConfig

func ValidateConfig(c Config) error

func ValidateConfigApi

func ValidateConfigApi(c Config) error

func WriteConfig

func WriteConfig(c Config) error

Types

type Config

type Config struct {
	ConfigWithoutSecrets
	ClientID     string
	ClientSecret string
}

func ReadConfig

func ReadConfig() Config

func (*Config) UpdateTrustedCAs

func (cfg *Config) UpdateTrustedCAs(caCerts []string) error

type ConfigWithoutSecrets

type ConfigWithoutSecrets struct {
	ApiURL             string
	AuthURL            string
	AccessToken        string
	RefreshToken       string
	InsecureSkipVerify bool
	CaCerts            []string
	ServerVersion      string
	HttpTimeout        *time.Duration
}

func ConvertConfigToConfigWithoutSecrets

func ConvertConfigToConfigWithoutSecrets(config Config) ConfigWithoutSecrets
GOOS=linux, GOARCH=amd64