更新 env/env.go
This commit is contained in:
parent
d645a49c97
commit
9bb2a1d730
|
@ -32,9 +32,14 @@ func NewEnv() *types.MeshEnv {
|
|||
func NewBaseEnv() *types.MeshEnv {
|
||||
if MeshEnv == nil {
|
||||
MeshEnv = &types.MeshEnv{
|
||||
Prefix: GetEnvDefault("BlocksMesh_Prefix", "/usr/local/bsm"),
|
||||
RuntimeMode: strings.ToLower(GetEnvDefault("BlocksMesh_RuntimeMode", "dev")),
|
||||
}
|
||||
|
||||
if MeshEnv.RuntimeMode == "dev" {
|
||||
MeshEnv.Prefix = GetEnvDefault("BlocksMesh_Prefix", utils.GetCurrentPath())
|
||||
} else {
|
||||
MeshEnv.Prefix = GetEnvDefault("BlocksMesh_Prefix", "/usr/local/bsm")
|
||||
}
|
||||
}
|
||||
return MeshEnv
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue