aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/run_tests/helper_scripts
diff options
context:
space:
mode:
authorGravatar murgatroid99 <mlumish@google.com>2017-06-15 17:48:42 -0700
committerGravatar murgatroid99 <mlumish@google.com>2017-06-15 17:48:42 -0700
commitd5b0455110b834c7fa102a0338882a4f98d31ae8 (patch)
treedcc9789852f362a5986709587475aee4822cd350 /tools/run_tests/helper_scripts
parentfb5ad8d2b9b5fc541a3a85703783fe8e7e4ee91b (diff)
parent2f850801235580217bb74c5911686bce0374dcad (diff)
Merge remote-tracking branch 'upstream/v1.4.x' into upmerge_1.4.x
Diffstat (limited to 'tools/run_tests/helper_scripts')
-rw-r--r--tools/run_tests/helper_scripts/pre_build_node.bat6
-rwxr-xr-xtools/run_tests/helper_scripts/pre_build_node.sh6
2 files changed, 8 insertions, 4 deletions
diff --git a/tools/run_tests/helper_scripts/pre_build_node.bat b/tools/run_tests/helper_scripts/pre_build_node.bat
index ff4d98aaee..ececc5755d 100644
--- a/tools/run_tests/helper_scripts/pre_build_node.bat
+++ b/tools/run_tests/helper_scripts/pre_build_node.bat
@@ -14,5 +14,7 @@
set PATH=%PATH%;C:\Program Files\nodejs\;%APPDATA%\npm
-@rem Expire cache after 1 day
-call npm update --cache-min 86400
+@rem Update npm to at least version 5
+call npm update -g npm
+
+call npm update --prefer-online
diff --git a/tools/run_tests/helper_scripts/pre_build_node.sh b/tools/run_tests/helper_scripts/pre_build_node.sh
index 5d14a549da..f41da71d22 100755
--- a/tools/run_tests/helper_scripts/pre_build_node.sh
+++ b/tools/run_tests/helper_scripts/pre_build_node.sh
@@ -20,10 +20,12 @@ source ~/.nvm/nvm.sh
nvm install $NODE_VERSION
set -ex
+# Update npm to at least version 5
+npm update -g npm
+
export GRPC_CONFIG=${CONFIG:-opt}
-# Expire cache after 1 day
-npm update --cache-min 86400
+npm update --prefer-online
npm install node-gyp-install
./node_modules/.bin/node-gyp-install