config

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2024 License: MIT Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BindAddr                   string        `envconfig:"BIND_ADDR"`
	CORSAllowedOrigins         string        `envconfig:"CORS_ALLOWED_ORIGINS"`
	ShutdownTimeout            time.Duration `envconfig:"SHUTDOWN_TIMEOUT"`
	HealthCheckCriticalTimeout time.Duration `envconfig:"HEALTHCHECK_CRITICAL_TIMEOUT"`
	HealthCheckInterval        time.Duration `envconfig:"HEALTHCHECK_INTERVAL"`
	OTBatchTimeout             time.Duration `encconfig:"OTEL_BATCH_TIMEOUT"`
	OTServiceName              string        `envconfig:"OTEL_SERVICE_NAME"`
	OTExporterOTLPEndpoint     string        `envconfig:"OTEL_EXPORTER_OTLP_ENDPOINT"`
	OtelEnabled                bool          `envconfig:"OTEL_ENABLED"`
	TableRendererHost          string        `envconfig:"TABLE_RENDERER_HOST"`
	ContentServerHost          string        `envconfig:"CONTENT_SERVER_HOST"`
	APIRouterURL               string        `envconfig:"API_ROUTER_URL"`
}

Config is the configuration for this service

func Get

func Get() (*Config, error)

Get configures the application and returns the configuration

func (*Config) Log

func (cfg *Config) Log(ctx context.Context)

Log writes all config properties to log.Debug

Jump to

Keyboard shortcuts

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