Skip to content

Instantly share code, notes, and snippets.

@ernestofreyreg
Last active March 6, 2021 01:05
Show Gist options
  • Save ernestofreyreg/a60246f5c7d29dfc908ba34ca386e2a5 to your computer and use it in GitHub Desktop.
Save ernestofreyreg/a60246f5c7d29dfc908ba34ca386e2a5 to your computer and use it in GitHub Desktop.
FROM mhart/alpine-node:10 AS builder
WORKDIR /app
COPY package.json .
RUN yarn install
COPY . .
RUN yarn build && yarn --production
FROM mhart/alpine-node:10
WORKDIR /app
COPY --from=builder /app .
EXPOSE 3000
CMD ["node_modules/.bin/next", "start"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment