config_service

package
v0.0.0-...-a72e5ba Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadIn

func ReadIn()

ReadIn reads all specified configuration sources and builds final aggregated configuration

Types

type ConfigService

type ConfigService struct {
	Verbose bool `mapstructure:"verbose"`

	// Service
	ServiceAddress string `mapstructure:"service-address"`

	// TLS
	TLS         bool   `mapstructure:"tls"`
	TLSCertFile string `mapstructure:"tls-cert-file"`
	TLSKeyFile  string `mapstructure:"tls-key-file"`

	// OAuth
	OAuth            bool   `mapstructure:"oauth"`
	JWTPublicKeyFile string `mapstructure:"jwt-public-key-file"`

	// Kafka connection
	Brokers []string `mapstructure:"brokers"`
	// Kafka internals
	Topic string `mapstructure:"topic"`

	// MinIO connection
	Endpoint        string `mapstructure:"endpoint"`
	AccessKeyID     string `mapstructure:"accessKeyID"`
	SecretAccessKey string `mapstructure:"secretAccessKey"`
	Secure          bool   `mapstructure:"secure"`
}

IMPORTANT IMPORTANT Do not forget to update String() function IMPORTANT

var Config ConfigService

Config is the configuration

func (*ConfigService) GetKafkaEndpoint

func (c *ConfigService) GetKafkaEndpoint() *atlas.KafkaEndpoint

Part of config.KafkaEndpointConfig interface

func (*ConfigService) GetMinIOAccessKeyID

func (c *ConfigService) GetMinIOAccessKeyID() string

Part of config.MinIOEndpointConfig interface

func (*ConfigService) GetMinIOEndpoint

func (c *ConfigService) GetMinIOEndpoint() string

Part of config.MinIOEndpointConfig interface

func (*ConfigService) GetMinIOSecretAccessKey

func (c *ConfigService) GetMinIOSecretAccessKey() string

Part of config.MinIOEndpointConfig interface

func (*ConfigService) GetMinIOSecure

func (c *ConfigService) GetMinIOSecure() bool

Part of config.MinIOEndpointConfig interface

func (*ConfigService) String

func (c *ConfigService) String() string

String returns string representation of the configuration

Jump to

Keyboard shortcuts

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