PLT-8289 Added ability to change location of client plugins (#7942)

Этот коммит содержится в:
Harrison Healey
2017-12-05 13:25:49 -05:00
коммит произвёл Chris
родитель 154a502f8e
Коммит 36777057f2
4 изменённых файлов: 26 добавлений и 19 удалений

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

@@ -26,7 +26,7 @@ func Init(api3 *api.API) {
l4g.Debug("Using client directory at %v", staticDir)
staticHandler := staticHandler(http.StripPrefix("/static/", http.FileServer(http.Dir(staticDir))))
pluginHandler := pluginHandler(api3.App.Config, http.StripPrefix("/static/plugins/", http.FileServer(http.Dir(staticDir+"plugins/"))))
pluginHandler := pluginHandler(api3.App.Config, http.StripPrefix("/static/plugins/", http.FileServer(http.Dir(*api3.App.Config().PluginSettings.ClientDirectory))))
if *api3.App.Config().ServiceSettings.WebserverMode == "gzip" {
staticHandler = gziphandler.GzipHandler(staticHandler)