Skip to content

Commit

Permalink
feat: updated dockerfile and revived docker functionality (#304)
Browse files Browse the repository at this point in the history
Co-authored-by: Sanchit Bajaj <[email protected]>
  • Loading branch information
Bhavya-55 and Sanchitbajaj02 authored May 17, 2024
1 parent af2e390 commit bf2ff2b
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
FROM node:18 as builder

FROM node:alpine
WORKDIR /app

# Update npm
RUN npm install -g npm@latest
COPY next.config.js .
COPY package.json .
COPY postcss.config.js .
COPY tailwind.config.js .
COPY tsconfig.json .
COPY yarn.lock .

# Install app dependencies
COPY ["package.json", "yarn.lock*", "./"]
#RUN npm install
RUN yarn install

# Copy source code
COPY . .

#RUN npm run build
RUN yarn build
EXPOSE 3000

# Create a non-root user and switch to it
# RUN chown -R node /app
# USER node

# Command to run on container start
CMD ["yarn", "dev"]
CMD ["yarn","start"]

0 comments on commit bf2ff2b

Please sign in to comment.