summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Zallmann <tzallmann@gitlab.com>2018-06-11 13:59:55 +0000
committerAlessio Caiazza <acaiazza@gitlab.com>2018-06-11 17:47:02 +0200
commit141ecb5afaa8ee4b4b6f76ac64f29d98b896d440 (patch)
treea50b8205651ba7bd0c4e5a19d65bc0ca31643acc
parentc0efed0199c899570ed7f825406e59a812e151ed (diff)
downloadgitlab-ce-141ecb5afaa8ee4b4b6f76ac64f29d98b896d440.tar.gz
Merge branch 'leipert-add-memory-info' into 'master'
Set `max_old_space_size` option of node to 3.5GB during compile:assets See merge request gitlab-org/gitlab-ce!19624
-rw-r--r--.gitlab-ci.yml7
-rw-r--r--config/webpack.config.js1
2 files changed, 7 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index e366538d907..fafc639eebf 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -394,7 +394,11 @@ compile-assets:
- date
- yarn install --frozen-lockfile --cache-folder .yarn-cache
- date
+ - free -m
- bundle exec rake gitlab:assets:compile
+ variables:
+ # we override the max_old_space_size to prevent OOM errors
+ NODE_OPTIONS: --max_old_space_size=3584
artifacts:
expire_in: 7d
paths:
@@ -658,10 +662,13 @@ gitlab:assets:compile:
SKIP_STORAGE_VALIDATION: "true"
WEBPACK_REPORT: "true"
NO_COMPRESSION: "true"
+ # we override the max_old_space_size to prevent OOM errors
+ NODE_OPTIONS: --max_old_space_size=3584
script:
- date
- yarn install --frozen-lockfile --production --cache-folder .yarn-cache
- date
+ - free -m
- bundle exec rake gitlab:assets:compile
artifacts:
name: webpack-report
diff --git a/config/webpack.config.js b/config/webpack.config.js
index e760ce1cb8c..b1e378f6c27 100644
--- a/config/webpack.config.js
+++ b/config/webpack.config.js
@@ -1,4 +1,3 @@
-const fs = require('fs');
const path = require('path');
const glob = require('glob');
const webpack = require('webpack');