mirror of
https://github.com/rancher/os.git
synced 2025-09-01 23:04:41 +00:00
Fix boot issues due to invalid configs
This commit is contained in:
@@ -22,11 +22,7 @@ import (
|
||||
|
||||
func CreateService(cfg *config.CloudConfig, name string, serviceConfig *composeConfig.ServiceConfigV1) (project.Service, error) {
|
||||
if cfg == nil {
|
||||
var err error
|
||||
cfg, err = config.LoadConfig()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
cfg = config.LoadConfig()
|
||||
}
|
||||
|
||||
p, err := CreateServiceSet("once", cfg, map[string]*composeConfig.ServiceConfigV1{
|
||||
@@ -195,11 +191,7 @@ func newCoreServiceProject(cfg *config.CloudConfig, useNetwork bool) (*project.P
|
||||
p.AddListener(projectEvents)
|
||||
|
||||
p.ReloadCallback = func() error {
|
||||
var err error
|
||||
cfg, err = config.LoadConfig()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
cfg = config.LoadConfig()
|
||||
|
||||
environmentLookup.SetConfig(cfg)
|
||||
|
||||
|
Reference in New Issue
Block a user