config

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RedisTLSProtocol = "TLS"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BindAddr                   string        `envconfig:"BIND_ADDR"`
	GracefulShutdownTimeout    time.Duration `envconfig:"GRACEFUL_SHUTDOWN_TIMEOUT"`
	HealthCheckInterval        time.Duration `envconfig:"HEALTHCHECK_INTERVAL"`
	HealthCheckCriticalTimeout time.Duration `envconfig:"HEALTHCHECK_CRITICAL_TIMEOUT"`
	OTBatchTimeout             time.Duration `encconfig:"OTEL_BATCH_TIMEOUT"`
	OTExporterOTLPEndpoint     string        `envconfig:"OTEL_EXPORTER_OTLP_ENDPOINT"`
	OTServiceName              string        `envconfig:"OTEL_SERVICE_NAME"`
	OtelEnabled                bool          `envconfig:"OTEL_ENABLED"`
	RedisAddress               string        `envconfig:"REDIS_ADDRESS"`
	RedirectAPIURL             string        `envconfig:"REDIRECT_API_URL"`
	RedisRegion                string        `envconfig:"REDIS_REGION"`
	RedisSecProtocol           string        `envconfig:"REDIS_SEC_PROTO"`
	RedisService               string        `envconfig:"REDIS_SERVICE"`
	RedisUsername              string        `envconfig:"REDIS_USERNAME"`
	AuthorisationConfig        *authorisation.Config
}

Config represents service configuration for dis-redirect-api

func Get

func Get() (*Config, error)

Get returns the default config with any modifications through environment variables

Jump to

Keyboard shortcuts

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