Skip to content

Commit

Permalink
update docker file to use yarn and copy in yarn.lock (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
jowparks authored Mar 20, 2024
1 parent ff7ff2d commit 87bf398
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,19 @@ WORKDIR /app

# Copy package.json and package-lock.json to the working directory
COPY package*.json ./
COPY yarn.lock ./

# Install any needed packages specified in package.json
RUN npm install
RUN npm install -g yarn

# Install any needed packages specified in package.json
RUN yarn

# Copy the rest of your app's source code to /app
COPY . .

# Build the app
RUN npm run build
RUN yarn build

# Define the command to run your app using CMD which defines your runtime
CMD ["npm", "run", "start"]
CMD ["yarn", "start"]

0 comments on commit 87bf398

Please sign in to comment.