config

package
v1.0.13 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Vault = "vault"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthenticationInfo

type AuthenticationInfo struct {
	AuthType  string
	AuthToken string
}

AuthenticationInfo contains authentication information to be used when communicating with an HTTP based provider

type BootstrapConfiguration

type BootstrapConfiguration struct {
	Service *ServiceInfo
}

BootstrapConfiguration defines the configuration elements required by the bootstrap.

type GeneralConfiguration

type GeneralConfiguration struct {
	LogLevel        string
	Service         ServiceInfo
	SecretStore     SecretStoreInfo
	InsecureSecrets InsecureSecrets
	Mqtt5Configs    Mqtt5Configs
}

func (*GeneralConfiguration) GetBootstrap added in v1.0.4

func (c *GeneralConfiguration) GetBootstrap() BootstrapConfiguration

GetBootstrap returns the configuration elements required by the bootstrap.

func (*GeneralConfiguration) GetInsecureSecrets added in v1.0.4

func (c *GeneralConfiguration) GetInsecureSecrets() InsecureSecrets

GetInsecureSecrets gets the config.InsecureSecrets field from the ConfigurationStruct.

func (*GeneralConfiguration) GetLogLevel added in v1.0.4

func (c *GeneralConfiguration) GetLogLevel() string

GetLogLevel returns the current ConfigurationStruct's log level.

func (*GeneralConfiguration) GetMqtt5Configs added in v1.0.4

func (c *GeneralConfiguration) GetMqtt5Configs() Mqtt5Configs

GetMqtt5Configs gets the config.Mqtt5Configs from the configuration struct.

type InsecureSecrets

type InsecureSecrets map[string]InsecureSecretsInfo

InsecureSecrets is used to hold the secrets stored in the configuration

type InsecureSecretsInfo

type InsecureSecretsInfo struct {
	SecretName string
	SecretData map[string]string
}

InsecureSecretsInfo encapsulates info used to retrieve insecure secrets

type Mqtt5Configs added in v1.0.4

type Mqtt5Configs map[string]models.Mqtt5Config

type SecretStoreInfo

type SecretStoreInfo struct {
	Type           string
	Host           string
	Port           int
	StoreName      string
	Protocol       string
	Namespace      string
	RootCaCertPath string
	ServerName     string
	Authentication AuthenticationInfo
	// TokenFile provides a location to a token file.
	TokenFile string
	// SecretsFile is optional Path to JSON file containing secrets to seed into service's SecretStore
	SecretsFile string
	// DisableScrubSecretsFile specifies to not scrub secrets file after importing. Service will fail start-up if
	// not disabled and file can not be written.
	DisableScrubSecretsFile bool
}

SecretStoreInfo encapsulates configuration properties used to create a SecretClient.

type ServiceInfo

type ServiceInfo struct {
	// Host is the hostname or IP address of the service.
	Host string
	// Port is the HTTP port of the service.
	Port int
	// ServerBindAddr specifies an IP address or hostname
	// for ListenAndServe to bind to, such as 0.0.0.0
	ServerBindAddr string
	// StartupMsg specifies a string to log once service
	// initialization and startup is completed.
	StartupMsg string
	// MaxResultCount specifies the maximum size list supported
	// in response to REST calls to other services.
	MaxResultCount int
	// MaxRequestSize defines the maximum size of http request body in kilobytes
	MaxRequestSize int64
	// RequestTimeout specifies a timeout (in ISO8601 format) for
	// processing REST request calls from other services.
	RequestTimeout string
}

ServiceInfo contains configuration settings necessary for the basic operation of any Edge service.

Jump to

Keyboard shortcuts

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