File tree Expand file tree Collapse file tree 6 files changed +6900
-13135
lines changed
Expand file tree Collapse file tree 6 files changed +6900
-13135
lines changed Original file line number Diff line number Diff line change 1- FROM node:14 -alpine
1+ FROM node:18 -alpine
22
3- WORKDIR /app
3+ # Set working directory
4+ ENV ROOT="/app"
5+ WORKDIR ${ROOT}
46
5- RUN apk update && apk upgrade
6- RUN apk add git
7+ # Copy package.json and package-lock.json before other files
8+ # Utilise Docker cache to save re-installing dependencies if unchanged
9+ COPY ./package*.json ./
10+ COPY ./pnpm-lock.yaml ./
711
8- COPY ./package*.json /app/
12+ RUN pnpm install --shamefully-hoist
913
10- RUN npm install && npm cache clean --force
11-
12- COPY . .
14+ # Copy all files
15+ COPY ./ ./
1316
1417ENV PATH ./node_modules/.bin/:$PATH
Original file line number Diff line number Diff line change 11version : ' 3.3'
22
33services :
4- nuxt :
4+ nuxt_docker_starter :
55 build :
66 context : .
7- image : nuxt_dev
8- container_name : nuxt_dev
7+ image : nuxt_dev_image
8+ container_name : nuxt_dev_container
99 command : npm run dev
1010 volumes :
1111 - .:/app
Original file line number Diff line number Diff line change 1- import { defineNuxtConfig } from 'nuxt'
2-
3- // https://v3.nuxtjs.org/api/configuration/nuxt.config
1+ // https://nuxt.com/docs/api/configuration/nuxt-config
42export default defineNuxtConfig ( {
5-
6- } )
3+ } ) ;
You can’t perform that action at this time.
0 commit comments