FROM node:14.3 as build
WORKDIR /app
COPY . ./
RUN yarn install -s
RUN yarn global add gatsby-cli
RUN gatsby build
FROM gatsbyjs/gatsby
COPY --from=build /app/public /pub