tour: fix for new app deployment

The app now runs in the root of the repo, so need to use "tour" not "." for tour root.

Fixes golang/go#46793.

Change-Id: I14499e0c662793789bc1a2603db9dd7c0e1011ad
Reviewed-on: https://go-review.googlesource.com/c/website/+/328675
Trust: Russ Cox <rsc@golang.org>
Run-TryBot: Russ Cox <rsc@golang.org>
Website-Publish: Russ Cox <rsc@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
This commit is contained in:
Russ Cox 2021-06-16 18:21:29 -04:00
Родитель f3510d6865
Коммит bfe83e6362
1 изменённых файлов: 4 добавлений и 2 удалений

Просмотреть файл

@ -21,14 +21,16 @@ func gaeMain() {
socketAddr = gaeSocketAddr
analyticsHTML = template.HTML(os.Getenv("TOUR_ANALYTICS"))
if err := initTour(".", "HTTPTransport"); err != nil {
root := "tour"
if err := initTour(root, "HTTPTransport"); err != nil {
log.Fatal(err)
}
http.Handle("/", hstsHandler(rootHandler))
http.Handle("/lesson/", hstsHandler(lessonHandler))
registerStatic(".")
registerStatic(root)
port := os.Getenv("PORT")
if port == "" {