refactor: update storage configuration to use environment variables

This commit is contained in:
Marco Pedone 2025-10-29 10:08:37 +01:00
parent 7630e4273b
commit a7e9f1d8ff

View file

@ -68,8 +68,8 @@ func Load() *Config {
Cfg.Images.Path = filepath.Join(pwd, "images")
// Storage config
Cfg.Storage.Endpoint = filepath.Join(pwd, "STORAGE_URL")
Cfg.Storage.Token = filepath.Join(pwd, "STORAGE_TOKEN")
Cfg.Storage.Endpoint = getEnv("STORAGE_URL", "")
Cfg.Storage.Token = getEnv("STORAGE_TOKEN", "")
// Server config
Cfg.Server.Port = getEnvAsInt("PORT", 1323)