Created
September 4, 2017 07:40
-
-
Save alefhsousa/2a47fb74ecf5cbd62f8579ccedc52b04 to your computer and use it in GitHub Desktop.
dockerfile with docker multi stage build for freeboard
This file contains hidden or 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:alpine as temp | |
| RUN apk update && \ | |
| apk upgrade && \ | |
| apk add nodejs git | |
| WORKDIR /app | |
| RUN git clone https://github.com/Freeboard/freeboard.git | |
| RUN cd /app/freeboard && npm install -g | |
| FROM nginx:1.12-alpine | |
| COPY --from=temp /app/freeboard/css/ /usr/share/nginx/html/css/ | |
| COPY --from=temp /app/freeboard/js/ /usr/share/nginx/html/js/ | |
| COPY --from=temp /app/freeboard/img/ /usr/share/nginx/html/img/ | |
| COPY --from=temp /app/freeboard/plugins/ /usr/share/nginx/html/plugins/ | |
| COPY --from=temp /app/freeboard/index.html /usr/share/nginx/html/ | |
| EXPOSE 80 | |
| RUN chown nginx.nginx /usr/share/nginx/html/ -R |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment