Explorar o código

feat: 完成了SonarQube静态代码测试的前端代码

claws %!s(int64=4) %!d(string=hai) anos
pai
achega
6e64f288b8
Modificáronse 1 ficheiros con 11 adicións e 0 borrados
  1. 11 0
      Dockerfile

+ 11 - 0
Dockerfile

@@ -0,0 +1,11 @@
+FROM node:12-alpine as builder
+WORKDIR /code
+RUN yarn config set registry https://registry.npm.taobao.org/
+ADD package.json /code
+ADD yarn.lock /code
+RUN yarn install
+ADD . /code
+RUN yarn build:prod
+
+FROM nginx:1.19-alpine
+COPY --from=builder /code/dist/ /var/www/html/dist/