config

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2022 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuthConfig

type AuthConfig struct {
	Jwt
}

type CacheConfig

type CacheConfig struct {
	Username    string
	Password    string
	Host        string
	Port        string
	RequireAuth bool
}

type Config

type Config struct {
	Host        string
	Env         string
	DocsEnabled bool
	Port        string
	Logging     LoggingConfig
	CorsHeaders string
	Version     string
	Database    DatabaseConfig
	Auth        AuthConfig
	Cache       CacheConfig
	Monitoring  MonitoringConfig
}

type DatabaseConfig

type DatabaseConfig struct {
	Host     string
	Database string
	User     string
	Password string
	Port     string
	IsSRV    bool
}

type Jwt

type Jwt struct {
	// Secret key used to sign the JWT token
	Secret string
	// ExpireDelta is the expiration time of the JWT Access token
	ExpireDelta int
	// RefreshExpirationDelta is the expiry time of the JWT Refresh token
	RefreshExpireDelta int
	// Issuer of the JWT token
	Issuer string
}

type LoggingConfig

type LoggingConfig struct {
	Debug            bool
	Level            string
	EnableJSONOutput bool
}

type MonitoringConfig

type MonitoringConfig struct {
	Sentry
}

type Sentry

type Sentry struct {
	DSN              string
	TracesSampleRate float64
	Environment      string
	Enabled          bool
}

Jump to

Keyboard shortcuts

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