Created
April 18, 2019 22:11
-
-
Save codyde/576fd5e8f7f889f80dfb40e062ea5782 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### STAGE 1: Build ### | |
FROM node:10.10-alpine as builder | |
COPY package.json package-lock.json ./ | |
RUN npm i && mkdir /ng-app && cp -R ./node_modules ./ng-app | |
WORKDIR /ng-app | |
COPY . . | |
RUN $(npm bin)/ng build --prod | |
### STAGE 2: Setup ### | |
FROM nginx:1.14-alpine | |
COPY nginx/default.conf /etc/nginx/conf.d/ | |
RUN rm -rf /usr/share/nginx/html/* | |
COPY --from=builder /ng-app/dist/cmbu-bootcamp-app /usr/share/nginx/html | |
CMD ["nginx", "-g", "daemon off;"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment