Skip to content

Instantly share code, notes, and snippets.

@ruyut

ruyut/Dockerfile Secret

Created April 18, 2023 15:28
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ruyut/6d3fcfafdb8e497b73ce63036f74d1aa to your computer and use it in GitHub Desktop.
Save ruyut/6d3fcfafdb8e497b73ce63036f74d1aa to your computer and use it in GitHub Desktop.
Dockerfile for Deploying Nuxt3 inside a Docker Container
FROM node:lts-alpine
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
# customize port 80
EXPOSE 80
CMD ["sh", "-c", "NITRO_PORT=80 node .output/server/index.mjs"]
# default port 3000
# EXPOSE 3000
# CMD ["node", ".output/server/index.mjs"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment