diff options
author | Christian Pointner <equinox@helsinki.at> | 2016-04-02 05:33:00 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2016-04-02 05:33:00 (GMT) |
commit | 89075959bf7ff1832cc38414a1ae392a49536294 (patch) | |
tree | 0e2c7f5f58d39c9b3eaf9899d3527e2b119a0d2b /src/rhimportd/ctrlWeb.go | |
parent | 27eaf84de6c5900c739f73725bd07270d43d49b7 (diff) |
added simple HTTP upload handler
Diffstat (limited to 'src/rhimportd/ctrlWeb.go')
-rw-r--r-- | src/rhimportd/ctrlWeb.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rhimportd/ctrlWeb.go b/src/rhimportd/ctrlWeb.go index 40075d0..70d8733 100644 --- a/src/rhimportd/ctrlWeb.go +++ b/src/rhimportd/ctrlWeb.go @@ -45,10 +45,11 @@ func (self webHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { } func StartControlWeb(addr string, conf *rhimport.Config, db *rddb.DBChan, sessions *rhimport.SessionStoreChan) { - http.Handle("/public/simple", webHandler{conf, db, sessions, false, webSimpleHandler}) // http.Handle("/trusted/simple", webHandler{conf, db, sessions, true, webSimpleHandler}) + http.Handle("/public/simple", webHandler{conf, db, sessions, false, webSimpleHandler}) http.Handle("/public/socket", webHandler{conf, db, sessions, false, webSocketHandler}) + http.Handle("/public/upload", webHandler{conf, db, sessions, false, webUploadHandler}) rhl.Println("web-ctrl: listening on", addr) server := &http.Server{Addr: addr, ReadTimeout: 60 * time.Second, WriteTimeout: 60 * time.Second} |