Skip to content

Commit

Permalink
Fixed Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
hschwentner committed Aug 4, 2022
1 parent be3c199 commit c370353
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
# Build stage
FROM trion/ng-cli-karma AS builder
LABEL maintainer="nicklas@wiegandt.eu,thesasch_github@wiegandt.net"
USER 1000
WORKDIR /tmp
# copy app files
FROM node:16-alpine AS build-stage
WORKDIR /app

COPY package.json ./
COPY package-lock.json ./
RUN npm ci

COPY . .
# install node packages
RUN npm install && \
#build package
npm run all

FROM nginx:stable-alpine
LABEL maintainer="nicklas@wiegandt.eu,thesasch_github@wiegandt.net"
COPY --from=builder --chown=101:101 /tmp/dist /usr/share/nginx/html

RUN npm run bundle


# Runtime stage
FROM nginx:1.22-alpine
COPY --from=build-stage /app/dist /usr/share/nginx/html

0 comments on commit c370353

Please sign in to comment.