From 23af62ef44e97d2694b7ba2f830edf79168d3bc3 Mon Sep 17 00:00:00 2001 From: Nathan Coad Date: Fri, 29 Dec 2023 10:15:49 +1100 Subject: [PATCH] retest --- .drone.sh | 3 ++- main.go | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.drone.sh b/.drone.sh index 61906f8..e27c75c 100644 --- a/.drone.sh +++ b/.drone.sh @@ -9,4 +9,5 @@ echo "build commences" go build -ldflags "-X main.sha1ver=`git rev-parse HEAD` -X main.buildTime=$now" -o smt echo "build complete" sha256sum smt > smt_checksum.txt -ls -lah \ No newline at end of file +ls -lah +ls -lah www \ No newline at end of file diff --git a/main.go b/main.go index 9936e9e..ba08784 100644 --- a/main.go +++ b/main.go @@ -29,7 +29,7 @@ type Replacements map[string]string var replacements = make(Replacements) -//go:embed www +//go:embed www/* var staticContent embed.FS // staticFileServer serves files from the provided fs.FS @@ -47,7 +47,7 @@ func staticFileServer(content embed.FS) gin.HandlerFunc { //log.Printf("staticFileServer attempting to load filename '%s'\n", fileName) // Try to open the file from the embedded FS - file, err := content.Open("www/" + fileName) + file, err := content.Open(fileName) if err != nil { c.String(http.StatusNotFound, "File not found") return