Skip to content

Commit

Permalink
Merge pull request #119 from jeiltodo/temp/common-client
Browse files Browse the repository at this point in the history
fix: dockerfile 수정
  • Loading branch information
Dragonite-Lee authored Aug 23, 2024
2 parents c024aba + 2870aa2 commit a47ff7f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 11 deletions.
3 changes: 1 addition & 2 deletions apps/admin/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,12 @@ RUN yarn build --filter=admin
FROM node:20-alpine AS runner
WORKDIR /app

COPY --from=builder /app/apps/admin/.next/standalone/apps/admin ./
COPY --from=builder /app/apps/admin/.next/standalone ./
COPY --from=builder /app/apps/admin/.next/static ./.next/static
COPY --from=builder /app/apps/admin/public ./public
COPY --from=builder /app/apps/admin/next.config.js ./next.config.js
COPY --from=builder /app/packages ./packages
COPY --from=builder /app/apps/admin/package.json ./packages
COPY --from=builder /app/node_modules/next ./node_modules/next

ENV PORT=3001

Expand Down
10 changes: 6 additions & 4 deletions apps/user/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,9 @@ WORKDIR /app

RUN apk add --no-cache bash curl

RUN npm i -g npm
RUN corepack enable && corepack prepare yarn@stable --activate

COPY package.json yarn.lock ./
COPY . .
RUN yarn install --frozen-lockfile

FROM node:20-alpine AS builder
Expand All @@ -19,9 +18,12 @@ RUN yarn build --filter=user
FROM node:20-alpine AS runner
WORKDIR /app

COPY --from=builder /app/apps/user/.next/standalone/apps/user ./
COPY --from=builder /app/apps/user/.next/standalone ./
COPY --from=builder /app/apps/user/.next/static ./.next/static
COPY --from=builder /app/apps/user/public ./public
COPY --from=builder /app/packages ./packages
COPY --from=builder /app/apps/user/next.config.js ./next.config.js
COPY --from=builder /app/apps/user/package.json ./packages

EXPOSE 3000
CMD ["node", "server.js"]
CMD ["node", "apps/user/server.js"]
5 changes: 0 additions & 5 deletions apps/user/next.config.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
const path = require('path');

/** @type {import('next').NextConfig} */
module.exports = {
output: 'standalone',
experimental: {
outputFileTracingRoot: path.join(__dirname, '../../'),
},
reactStrictMode: true,
transpilePackages: ['@jeiltodo/ui'],
eslint: {
Expand Down

0 comments on commit a47ff7f

Please sign in to comment.