diff options
| -rw-r--r-- | main.go | 9 | ||||
| -rw-r--r-- | resources/footer.html | 8 |
2 files changed, 9 insertions, 8 deletions
@@ -54,7 +54,14 @@ func okHandler(w http.ResponseWriter, r *http.Request) { indexBodyStart(w) indexBodyScanConfig(w) indexDivEnd(w) - writeFile(w, "footer.html") + pfile, err := os.ReadFile("/etc/gowebd/footer.html") + if err == nil { + fmt.Fprint(w, string(pfile)) + } else { + log.Warn(err, "no footer filee found in /etc/gowebd/footer.html") + log.Warn("falling back to the resources/footer.html") + writeFile(w, "footer.html") + } indexBodyEnd(w) return } diff --git a/resources/footer.html b/resources/footer.html index 1501276..3e0baf0 100644 --- a/resources/footer.html +++ b/resources/footer.html @@ -1,9 +1,3 @@ <br> -echo deb http://mirrors.wit.com/wit/ sid main > /etc/apt/sources.list.d/wit.list <br> -apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4A854AEAF7E0E16D <br> -apt update<br> -apt install go-clone # replicates the old 'go get' behavior<br> -apt install go-deb # make a debian package from a golang project<br> -apt install networkquality # debian package of apple's command line speedtest tool<br> -apt install virtigo # virt-manager from the command line (runs wit.com)<br> +your footer here<br> <br> |
