1
0
mirror of https://github.com/rancher/os.git synced 2025-07-22 10:51:33 +00:00

Merge pull request #1199 from joshwget/fix-upgrade-console

Fix --upgrade-console flag for upgrade
This commit is contained in:
Darren Shepherd 2016-08-29 15:31:14 -07:00 committed by GitHub
commit 2e6f31599a

View File

@ -107,14 +107,14 @@ func (s *Service) shouldRebuild(ctx context.Context) (bool, error) {
if newRebuildLabel == "always" {
return true, nil
}
if s.Name() == "console" && cfg.Rancher.ForceConsoleRebuild {
if err := config.Set("rancher.force_console_rebuild", false); err != nil {
return false, err
}
return true, nil
}
if outOfSync {
if s.Name() == "console" {
if cfg.Rancher.ForceConsoleRebuild {
if err := config.Set("rancher.force_console_rebuild", false); err != nil {
return false, err
}
return true, nil
}
origConsoleLabel := containerInfo.Config.Labels[config.CONSOLE]
newConsoleLabel := s.Config().Labels[config.CONSOLE]
if newConsoleLabel != origConsoleLabel {