Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

upgrade: Use restart-server unless --skip-puppet is used.

Mateusz Manderadd7f3a1dce13
diff --git a/scripts/lib/upgrade-zulip-stage-2 b/scripts/lib/upgrade-zulip-stage-2
index 724dad845bb..50b85379e1e 100755
--- a/scripts/lib/upgrade-zulip-stage-2
+++ b/scripts/lib/upgrade-zulip-stage-2
@@ -310,7 +310,10 @@ if migrations_needed:
subprocess.check_call(["./manage.py", "create_realm_internal_bots"], preexec_fn=su_to_zulip)
logging.info("Restarting Zulip...")
-if IS_SERVER_UP:
+if IS_SERVER_UP or not args.skip_puppet:
+ # Even if the server wasn't up previously, puppet might have
+ # started it if there were supervisord configuration changes, so
+ # we need to use restart-server if puppet ran.
subprocess.check_output(["./scripts/restart-server", "--fill-cache"], preexec_fn=su_to_zulip)
else:
subprocess.check_output(["./scripts/start-server", "--fill-cache"], preexec_fn=su_to_zulip)