config

package
v0.0.0-...-c98df5a Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	Key []string `mapstructure:"key"`
}

type Cache

type Cache struct {
	Source string        `mapstructure:"source"`
	Age    time.Duration `mapstructure:"age"`
}

type Config

type Config struct {
	Server       HTTP   `mapstructure:"http"`
	Iframely     API    `mapstructure:"api"`
	DB           DB     `mapstructure:"db"`
	MigrationURL string `mapstructure:"migration_url"`
	Cache        Cache  `mapstructure:"cache"`
	Jaeger       Jaeger `mapstructure:"jaeger"`
	TemplateFS   fs.FS
}

Config struct base from structure's config file

func Load

func Load() (c Config, err error)

Load config from input file (yaml)

func (*Config) InsertFS

func (c *Config) InsertFS(input fs.FS)

type DB

type DB struct {
	Source string `mapstructure:"source"`
}

type HTTP

type HTTP struct {
	Address string `mapstructur:"address"`
	Port    string `mapstructure:"port"`
}

type Jaeger

type Jaeger struct {
	Source string `mapstructure:"source"`
}

Jump to

Keyboard shortcuts

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