config

package
v0.0.0-...-c6724dc Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	Port string `yaml:"cachePort" envconfig:"CACHE_PORT"`
	Host string `yaml:"cacheHost" envconfig:"CACHE_HOST"`
}

type Config

type Config struct {
	Service Service `yaml:"service"`
	Cache   Cache   `yaml:"cache"`
	Pow     Pow     `yaml:"pow"`
}

func Load

func Load(configFile string) (*Config, error)

type Pow

type Pow struct {
	Complexity    int   `yaml:"complexity" envconfig:"POW_COMPLEXITY"`
	Expiration    int64 `yaml:"expiration" envconfig:"POW_EXPIRATION"`
	MaxIterations int   `yaml:"maxIterations" envconfig:"POW_MAX_ITERATIONS"`
}

type Service

type Service struct {
	Port     string `yaml:"port" envconfig:"SERVICE_PORT"`
	Host     string `yaml:"host" envconfig:"SERVICE_HOST"`
	DataFile string `yaml:"dataFile" envconfig:"DATA_FILE"`
}

Jump to

Keyboard shortcuts

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