fix static file access in docker
1 file changed, 15 insertions(+), 0 deletions(-)
changed files
A templates/files.go
@@ -0,0 +1,15 @@ +package templates + +import ( + "os" +) + +var Files = os.DirFS(getEnvFallback("KO_DATA_PATH", "cmd/server/kodata")) + +func getEnvFallback(key, fallback string) string { + if value, found := os.LookupEnv(key); found { + return value + } + + return fallback +}