You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
513 B
30 lines
513 B
#YangLiu Frontend Docker Build
|
|
|
|
FROM node:16.14.2
|
|
|
|
LABEL authors="YangLiu <YangLiusupport@163.com>"
|
|
|
|
WORKDIR /usr/src/app
|
|
|
|
COPY package.json package.json
|
|
|
|
RUN npm config set registry https://registry.npm.taobao.org \
|
|
&& npm i
|
|
|
|
COPY ./src ./src
|
|
RUN npm install -g @angular/cli
|
|
|
|
RUN ng build --prod --base-href /maxkey/
|
|
|
|
FROM nginx
|
|
|
|
COPY ./nginx.conf /etc/nginx/conf.d/default.conf
|
|
|
|
#RUN rm -rf /usr/share/nginx/html/*
|
|
|
|
COPY dist /usr/share/nginx/html/maxkey
|
|
|
|
#CMD ["nginx", "-g", "daemon off;"]
|
|
|
|
EXPOSE 8527
|