fix: take directory of executable path in config

This commit is contained in:
akp 2024-12-03 19:25:25 +00:00
parent 6286d01178
commit 96ffc31849
No known key found for this signature in database
GPG key ID: CF8D58F3DEB20755

View file

@ -71,7 +71,7 @@ func Load() (*Config, error) {
Platform: &Platform{
SitesDirectory: cl.Get("platform.sitesDirectory").Required().AsString(),
MaxUploadSizeMegabytes: cl.Get("platform.maxUploadSizeMegabytes").WithDefault(512).AsInt(),
CaddyExecutablePath: cl.Get("platform.caddyExecutablePath").WithDefault(path.Join(exePath, "caddy")).AsString(),
CaddyExecutablePath: cl.Get("platform.caddyExecutablePath").WithDefault(path.Join(path.Dir(exePath), "caddy")).AsString(),
},
}