|
|
@ -223,12 +223,12 @@ func runWeb() { |
|
|
|
router.HandleFunc("/api/login", tryLogin) |
|
|
|
router.HandleFunc("/api/login", tryLogin) |
|
|
|
router.HandleFunc("/api/pending", getPending) |
|
|
|
router.HandleFunc("/api/pending", getPending) |
|
|
|
router.HandleFunc("/api/verifications", getVerifications) |
|
|
|
router.HandleFunc("/api/verifications", getVerifications) |
|
|
|
router.HandleFunc("/verifications", getVerification) |
|
|
|
|
|
|
|
router.HandleFunc("/api/probations", getProbations) |
|
|
|
router.HandleFunc("/api/probations", getProbations) |
|
|
|
router.HandleFunc("/api/passreq", reqPass) |
|
|
|
router.HandleFunc("/api/passreq", reqPass) |
|
|
|
router.HandleFunc("/api/user", getUser) |
|
|
|
router.HandleFunc("/api/user", getUser) |
|
|
|
router.HandleFunc("/", greetUser) |
|
|
|
router.HandleFunc("/", greetUser) |
|
|
|
router.PathPrefix("/static/").Handler(http.StripPrefix("/static/", http.FileServer(http.Dir("./static")))) |
|
|
|
router.PathPrefix("/static/").Handler(http.StripPrefix("/static/", http.FileServer(http.Dir("./static")))) |
|
|
|
|
|
|
|
router.PathPrefix("/verifications/").Handler(http.StripPrefix("/verifications/", http.FileServer(http.Dir("./verifications")))) |
|
|
|
log.LogInfo("Starting server") |
|
|
|
log.LogInfo("Starting server") |
|
|
|
log.LogErrorType(http.ListenAndServe(":8080", router)) |
|
|
|
log.LogErrorType(http.ListenAndServe(":8080", router)) |
|
|
|
} |
|
|
|
} |
|
|
|