mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-21 17:21:09 +01:00
增加构建参数:NPM_DISABLE_SAFE_PERM 表示是否启用不验证npm证书模式,用来解决某些构建环境下npm报错的问题
true:开启 false:关闭 升级node8.0 到 lts版本(10.x)
This commit is contained in:
@@ -8,7 +8,15 @@ ENV GOPROXY https://mirrors.aliyun.com/goproxy/
|
||||
|
||||
RUN go install -v ./...
|
||||
|
||||
FROM node:8.16.0-alpine AS frontend-build
|
||||
FROM node:lts-alpine AS frontend-build
|
||||
|
||||
ARG NPM_DISABLE_SAFE_PERM=false
|
||||
RUN if [ ${NPM_DISABLE_SAFE_PERM} = true ]; then \
|
||||
# run the install
|
||||
echo "info: use npm unsafe-perm mode" \
|
||||
&& npm config set unsafe-perm true \
|
||||
;fi
|
||||
|
||||
|
||||
ADD ./frontend /app
|
||||
WORKDIR /app
|
||||
|
||||
Reference in New Issue
Block a user