13 lines
403 B
Docker
13 lines
403 B
Docker
|
FROM johnpapa/angular-cli as angular
|
||
|
WORKDIR /app
|
||
|
COPY package.json /app/
|
||
|
RUN npm cache clear --force && npm install
|
||
|
COPY ./ /app/
|
||
|
ARG env=dev
|
||
|
ARG aot=--no-aot
|
||
|
RUN ng build --$env --$aot
|
||
|
|
||
|
# Stage 1, based on Nginx, to have only the compiled app, ready for production with Nginx
|
||
|
FROM nginx:1.13
|
||
|
COPY --from=angular /app/dist/ /usr/share/nginx/html
|
||
|
COPY ./nginx-custom.conf /etc/nginx/conf.d/default.conf
|