Files
graphql-engine/community/learn/graphql-tutorials/tutorials/react-apollo/app-boilerplate/Dockerfile
2019-04-24 16:57:27 +05:30

21 lines
414 B
Docker

FROM node:carbon
# Create app directory
WORKDIR /app
# Install app dependencies
RUN npm -g install serve
# A wildcard is used to ensure both package.json AND package-lock.json are copied
COPY package*.json ./
RUN npm install
# Bundle app source
COPY src /app
#Build react/vue/angular bundle static files
RUN npm run build
EXPOSE 8080
# serve dist folder on port 8080
CMD ["serve", "-s", "dist", "-p", "8080"]