Created
April 4, 2021 06:08
-
-
Save bbachi/bf18383d88e0a6c9db5a337c895219a2 to your computer and use it in GitHub Desktop.
webapp
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
FROM node:10 AS ui-build | |
WORKDIR /usr/src/app | |
COPY my-app/ ./my-app/ | |
RUN cd my-app && npm install && npm run build | |
FROM node:10 AS server-build | |
WORKDIR /root/ | |
COPY --from=ui-build /usr/src/app/my-app/dist ./my-app/dist | |
COPY api/package*.json ./api/ | |
RUN cd api && npm install | |
COPY api/server.js ./api/ | |
EXPOSE 3080 | |
CMD ["node", "./api/server.js"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment