upgrade-zulip-from-git: Require more memory to run webpack.

Since the upgrade to Webpack 5, we've been seeing occasional reports
that servers with roughly 4GiB of RAM were getting OOM kills while
running webpack.

Since we can't readily optimize the memory requirements for webpack
itself, we should raise the RAM requirements for doing the
lower-downtime upgrade strategy.

Fixes #20231.
This commit is contained in:
Tim Abbott 2021-12-07 15:09:36 -08:00
parent 8f991f8eb1
commit 72b381d749
1 changed files with 2 additions and 2 deletions

View File

@ -206,8 +206,8 @@ elif args.from_git:
# Ideally, we'd have 2 thresholds here, depending on whether the # Ideally, we'd have 2 thresholds here, depending on whether the
# system is running queue workers multithreaded or multiprocess. # system is running queue workers multithreaded or multiprocess.
# See puppet/zulip/manifests/app_frontend_base.pp for background. # See puppet/zulip/manifests/app_frontend_base.pp for background.
if mem_gib < 3.8: if mem_gib < 4.2:
logging.info("Shutting down server to build static assets on a low-RAM system.") logging.info("Shutting down server to ensure sufficient free RAM for webpack.")
shutdown_server() shutdown_server()
# Note: The fact that this is before we apply Puppet changes means # Note: The fact that this is before we apply Puppet changes means