Move sleep note out of host loop, so we only see it once

This commit is contained in:
David Heinemeier Hansson
2023-02-26 11:19:30 +01:00
parent 27279c6c82
commit 701f6ff237
2 changed files with 2 additions and 6 deletions

View File

@@ -55,7 +55,7 @@ class Mrsk::Cli::Main < Mrsk::Cli::Base
MRSK.version = version
if container_name_available?(MRSK.config.service_with_version)
say "Start version #{version}, then stop the old version...", :magenta
say "Start version #{version}, then wait #{MRSK.config.readiness_delay}s for app to boot before stopping the old version...", :magenta
cli = self
@@ -64,7 +64,6 @@ class Mrsk::Cli::Main < Mrsk::Cli::Base
execute *MRSK.app.start
cli.say "Waiting #{MRSK.config.readiness_delay}s for app to start...", :magenta
sleep MRSK.config.readiness_delay
execute *MRSK.app.stop(version: old_version), raise_on_non_zero_exit: false