MM-10367: rewrite subpath assets on startup (#8944)
Examine ServiceSettings.SiteURL on startup and rewrite assets accordingly if not in a development environment. Also export `mattermost config subpath` command to manually do same. This accompanies a webapp PR to use the updated `root.html` to define the necessary webpack asset path for dynamically loading assets.
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
d0cda0500e
Коммит
f106417103
@@ -18,6 +18,8 @@ import (
|
||||
|
||||
func (w *Web) InitStatic() {
|
||||
if *w.App.Config().ServiceSettings.WebserverMode != "disabled" {
|
||||
UpdateAssetsSubpathFromConfig(w.App.Config())
|
||||
|
||||
staticDir, _ := utils.FindDir(model.CLIENT_DIR)
|
||||
mlog.Debug(fmt.Sprintf("Using client directory at %v", staticDir))
|
||||
|
||||
|
||||
Ссылка в новой задаче
Block a user