mirror of
https://github.com/h44z/wg-portal.git
synced 2025-09-15 07:11:15 +00:00
chore: use interfaces for all other services
This commit is contained in:
@@ -10,6 +10,7 @@ import (
|
||||
"gopkg.in/yaml.v3"
|
||||
)
|
||||
|
||||
// Config is the main configuration struct.
|
||||
type Config struct {
|
||||
Core struct {
|
||||
// AdminUser defines the default administrator account that will be created
|
||||
@@ -179,6 +180,7 @@ func GetConfig() (*Config, error) {
|
||||
return cfg, nil
|
||||
}
|
||||
|
||||
// loadConfigFile loads the configuration from a YAML file into the given cfg struct.
|
||||
func loadConfigFile(cfg any, filename string) error {
|
||||
data, err := envsubst.ReadFile(filename)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user