-
Notifications
You must be signed in to change notification settings - Fork 1
[All-Chore] 도커 세팅 #427
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
[All-Chore] 도커 세팅 #427
Changes from 5 commits
22c0bf2
2eec64a
cd37fc4
d07051a
4ff3b54
072258c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| FROM node:20-slim AS base | ||
| WORKDIR /app | ||
| RUN corepack enable pnpm && corepack install -g pnpm@latest-10 | ||
|
|
||
| FROM base AS builder | ||
| COPY pnpm-lock.yaml pnpm-workspace.yaml ./ | ||
| COPY packages ./packages | ||
| COPY configs ./configs | ||
| COPY apps ./apps | ||
|
|
||
| RUN pnpm fetch -r | ||
| COPY . ./ | ||
| RUN pnpm install -r | ||
| RUN pnpm build | ||
|
|
||
| RUN pnpm --filter @endolphin/server --prod deploy ./build/server | ||
| COPY ./apps/client/dist ./build/client | ||
|
|
||
| FROM base AS stage | ||
| COPY --from=builder /app/package.json ./package.json | ||
| COPY --from=builder /app/build/client ./client | ||
| COPY --from=builder /app/build/server/dist ./server | ||
| COPY --from=builder /app/build/server/package.json ./server/package.json | ||
| COPY --from=builder /app/build/server/node_modules ./server/node_modules | ||
|
|
||
| EXPOSE 5173 | ||
| ENV NODE_ENV=production | ||
| CMD ["pnpm", "start"] | ||
|
Comment on lines
+20
to
+28
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Final stage missing runtime dependencies and incorrect entrypoint. You only copy server’s
Without this, the container will error on startup. 🤖 Prompt for AI Agents |
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -6,7 +6,8 @@ | |||||||||||||||||||||||||||||||
| "type": "module", | ||||||||||||||||||||||||||||||||
| "scripts": { | ||||||||||||||||||||||||||||||||
| "build": "cross-env NODE_ENV=build tsup", | ||||||||||||||||||||||||||||||||
| "start": "cross-env NODE_ENV=start tsup --watch" | ||||||||||||||||||||||||||||||||
| "dev": "cross-env NODE_ENV=start tsup --watch", | ||||||||||||||||||||||||||||||||
| "start": "node index.js" | ||||||||||||||||||||||||||||||||
|
Comment on lines
+9
to
+10
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Missing You reference Apply this diff: "scripts": {
- "dev": "cross-env NODE_ENV=start tsup --watch",
+ "dev": "cross-env NODE_ENV=development tsup --watch",
- "start": "node index.js"
+ "start": "cross-env NODE_ENV=production node index.js"
},
"devDependencies": {
+ "cross-env": "^7.0.3",
"@types/express": "^5.0.2",
"typescript": "^5.6.2",
"@endolphin/tsup-config": "workspace:^",
"@endolphin/vitest-config": "workspace:^"📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||||||||
| "dependencies": { | ||||||||||||||||||||||||||||||||
| "express": "^5.1.0" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,7 @@ | ||
| packages: | ||
| - "apps/*" | ||
| - "packages/*" | ||
| - "configs/*" | ||
| - "configs/*" | ||
| injectWorkspacePackages: true | ||
| syncInjectedDepsAfterScripts: | ||
| - build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Invalid
deploytarget for@endolphin/server.There’s no
deployscript infrontend/apps/server/package.json, so this command will fail. Did you mean:or another custom script?
🤖 Prompt for AI Agents