mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2026-02-04 14:33:01 +08:00
fix: 解决部分情况下缓存目录导致启动失败的问题 (#6364)
Refs https://github.com/1Panel-dev/1Panel/issues/6362
This commit is contained in:
4
backend/init/cache/cache.go
vendored
4
backend/init/cache/cache.go
vendored
@@ -1,6 +1,7 @@
|
||||
package cache
|
||||
|
||||
import (
|
||||
"os"
|
||||
"time"
|
||||
|
||||
"github.com/1Panel-dev/1Panel/backend/global"
|
||||
@@ -10,7 +11,8 @@ import (
|
||||
|
||||
func Init() {
|
||||
c := global.CONF.System.Cache
|
||||
|
||||
_ = os.RemoveAll(c)
|
||||
_ = os.Mkdir(c, 0644)
|
||||
options := badger.Options{
|
||||
Dir: c,
|
||||
ValueDir: c,
|
||||
|
||||
Reference in New Issue
Block a user