diff options
author | Ian Lewis <ianlewis@google.com> | 2019-12-05 20:55:19 -0500 |
---|---|---|
committer | Ian Lewis <ianlewis@google.com> | 2020-01-14 17:00:07 +0900 |
commit | 89ac3bdc31d85412a9ce2073e96313588f6fb636 (patch) | |
tree | 2d65149b48392c964ba0da691fdc99f9d37053c4 | |
parent | eef069778b020e02d36c546ce9c92894254a75aa (diff) |
Run npm in Docker image.
This partially removes the build dependency on node.js.
-rw-r--r-- | Makefile | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -1,7 +1,6 @@ HUGO := hugo HUGO_VERSION := 0.53 HTMLPROOFER_VERSION := 3.10.2 -NPM := npm GCLOUD := gcloud GCP_PROJECT := gvisor-website @@ -55,7 +54,14 @@ static-staging: compatibility-docs node_modules config.toml $(shell find archety node_modules: package.json package-lock.json # Use npm ci because npm install will update the package-lock.json. # See: https://github.com/npm/npm/issues/18286 - $(NPM) ci + docker run \ + -e USER="$(shell id -u)" \ + -e HOME="/tmp" \ + -u="$(shell id -u):$(shell id -g)" \ + -v $(PWD):/workspace \ + -w /workspace \ + --entrypoint 'npm' \ + node ci upstream/gvisor/bazel-bin/runsc/linux_amd64_pure_stripped/runsc: upstream-gvisor mkdir -p /tmp/gvisor-website/build_output |