Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Did string `koanf:"did" yaml:"did"` Identifier string `koanf:"identifier" yaml:"identifier"` RefreshJwt string `koanf:"refresh_jwt" yaml:"refresh_jwt"` AccessJwt string `koanf:"-" yaml:"-"` // do not marshal this field AppPassword string `koanf:"-" yaml:"-"` // do not marshal this field Path string `koanf:"-" yaml:"-"` // do not marshal this field Server string `koanf:"server,omitempty" yaml:"server,omitempty"` Debug bool `koanf:"debug,omitempty" yaml:"debug,omitempty"` }
func (*Config) Load ¶
Load loads the configuration from the specified file path and environment variables. if the file does not exist, it will return an empty Config struct.
Parameters:
- path: The file path to the YAML configuration file.
Returns:
- *Config: A pointer to the loaded Config struct.
- error: An error if any occurred during the loading process.
Click to show internal directories.
Click to hide internal directories.