config

package
v1.9.1 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2023 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 Async

type Async struct {
	Run      bool
	Interval utils.Duration
}

type Config

type Config struct {
	// set in flags
	Version     string
	Environment string
	Port        int
	Database    string
	DSN         string
	// contains filtered or unexported fields
}

func ReadConfig

func ReadConfig(version, env string, port int, database, dsn, configPath string) (Config, error)

ReadConfig from the project´s JSON config files. Default values are specified in the default configuration file, config/config.json and can be overrided with values specified in the environment configuration files, config/config.{env}.json.

Jump to

Keyboard shortcuts

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