fixes
parent
b04262ae5d
commit
d98bebbd50
|
@ -247,8 +247,8 @@ func main() {
|
|||
// http.Redirect(w, r, "//club.hugeping.ru/blog/std.hugeping", http.StatusSeeOther)
|
||||
// })
|
||||
|
||||
http.Handle("hugeping.ru/", http.FileServer(http.Dir("/home/pi/Devel/gemini/www")))
|
||||
http.Handle("syscall.ru/", http.FileServer(http.Dir("/home/pi/Devel/gemini/www")))
|
||||
// http.Handle("hugeping.ru/", http.FileServer(http.Dir("/home/pi/Devel/gemini/www")))
|
||||
// http.Handle("syscall.ru/", http.FileServer(http.Dir("/home/pi/Devel/gemini/www")))
|
||||
|
||||
if err := http.ListenAndServe(*listen_opt, nil); err != nil {
|
||||
ii.Error.Printf("Error running web server: %s", err)
|
||||
|
|
|
@ -915,10 +915,10 @@ func WebInit(www *WWW) {
|
|||
|
||||
tpl_path := "tpl"
|
||||
if _, err := os.Stat(tpl_path); errors.Is(err, os.ErrNotExist) {
|
||||
fmt.Println("./tpl dir not exist")
|
||||
fmt.Println("./tpl not found, trying /usr/local/share/ii-go/tpl..")
|
||||
tpl_path = "/usr/local/share/ii-go/tpl"
|
||||
if _, err := os.Stat(tpl_path); errors.Is(err, os.ErrNotExist) {
|
||||
fmt.Println(tpl_path, "dir not exist")
|
||||
fmt.Println(tpl_path, "not found")
|
||||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue