v1.5.1 增强程序稳定性
This commit is contained in:
@@ -43,15 +43,16 @@ func NewSystemServiceManager() *SystemServiceManager {
|
||||
}
|
||||
|
||||
func (this *SystemServiceManager) Setup() error {
|
||||
if sharedNodeConfig == nil || !sharedNodeConfig.IsOn {
|
||||
var cfg = nodeConfig()
|
||||
if cfg == nil || !cfg.IsOn {
|
||||
return nil
|
||||
}
|
||||
|
||||
if len(sharedNodeConfig.SystemServices) == 0 {
|
||||
if len(cfg.SystemServices) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
systemdParams, ok := sharedNodeConfig.SystemServices[nodeconfigs.SystemServiceTypeSystemd]
|
||||
systemdParams, ok := cfg.SystemServices[nodeconfigs.SystemServiceTypeSystemd]
|
||||
if ok {
|
||||
err := this.setupSystemd(systemdParams)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user