1 Commits
Author SHA1 Message Date
sm 31cd542929 with SM_STATIC ENV variable 2015-02-09 22:33:17 -08:00
+5 -2
View File
@@ -1,12 +1,15 @@
package main package main
import "net/http" import (
"net/http"
"os"
)
func main() { func main() {
http.Handle( http.Handle(
"/", "/",
http.FileServer( http.FileServer(
http.Dir("."), http.Dir(os.Getenv("SM_STATIC")),
), ),
) )
if err := http.ListenAndServe(":8000", nil); err != nil { if err := http.ListenAndServe(":8000", nil); err != nil {