Move static to resources. Embed them at build time

This commit is contained in:
Deluan
2020-05-01 14:35:57 -04:00
committed by Deluan Quintão
parent b7dcdedf41
commit 1a9663d432
13 changed files with 39 additions and 367 deletions
+2 -3
View File
@@ -6,7 +6,6 @@ import (
"net/http"
"sync"
"github.com/deluan/navidrome/consts"
"github.com/deluan/navidrome/log"
)
@@ -14,7 +13,7 @@ var once sync.Once
func AssetFile() http.FileSystem {
once.Do(func() {
log.Warn("Using external assets from " + consts.UIAssetsLocalPath)
log.Warn("Using external assets from 'ui/build' folder")
})
return http.Dir(consts.UIAssetsLocalPath)
return http.Dir("ui/build")
}