Your message dated Sat, 20 Feb 2021 01:42:31 +0530
with message-id <[email protected]>
and subject line closing bug fixed long back
has caused the Debian Bug report #956508,
regarding gitlab: webpack should build assets in production mode
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
956508: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=956508
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: gitlab
Version: 12.9.2-4
Severity: normal

Current assets building through webpack is done by the following call
set in /usr/lib/gitlab/scripts/rake-tasks.sh:

runuser -u ${gitlab_user} -- sh -c 'NODE_OPTIONS="--max-old-space-size=2048" 
webpack --max-old-space-size=16384 --config config/webpack.config.js'

The issue with this command is that it does not build assets optimized
for use in production, making parts of the GitLab interface heavy on
bandwidth usage, and slow to use on networks with limited bandwidth.

The suggested replacement should fix this issue by explicitely building
assets optimized for production use:

runuser -u ${gitlab_user} -- sh -c 'NODE_ENV="production" 
NODE_OPTIONS="--max-old-space-size=4096" webpack --config 
config/webpack.config.js'

The modifications are:
- Add NODE_ENV="production", this is what triggers the correct assets
  build mode
- Replace NODE_OPTIONS="--max-old-space-size=2048" by
  NODE_OPTIONS="--max-old-space-size=4096", as it seems build in
  production mode uses more memory (an alternative would be to make the
  value configurable in /etc/gitlab/gitlab-debian.conf)
- Drop --max-old-space-size=16384 as it has no effect here, and probably
  was added by mistake while fixing #956211

Thanks to these tweaks, served assets are much smaller and the overall
UI is much more responsive. As an example it takes main.chunk.js from
~25 MB to less than 3MB, before application of gzip compression by
nginx.

For a comparison, both of these GitLab instances use the same GitLab
version based on buster-fasttrack repositories:
- https://gitlab.debian.net/explore - not using the production assets
- https://forge.dotslashplay.it/explore - using the production assets
The difference in responsiveness is easily noticeable, and the
difference is bandwidth usage is important.

--- End Message ---
--- Begin Message ---
cleanup, closing already fixed bug.

--- End Message ---
_______________________________________________
Pkg-ruby-extras-maintainers mailing list
[email protected]
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-ruby-extras-maintainers

Reply via email to