-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3453 from HHS/hotfix/hmr
fix: fixed hmr
- Loading branch information
Showing
1 changed file
with
5 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
# Use the official Bun image (using a tag version for consistency) | ||
FROM oven/bun:1 AS base | ||
WORKDIR /usr/src/app | ||
WORKDIR /home/app | ||
|
||
# Stage to install only production dependencies | ||
FROM base AS prod-deps | ||
RUN mkdir -p /temp/prod | ||
COPY package.json bun.lockb /temp/prod/ | ||
WORKDIR /temp/prod | ||
RUN mkdir -p /home/app | ||
COPY package.json bun.lockb /home/app/ | ||
WORKDIR /home/app | ||
RUN bun install --frozen-lockfile --production | ||
|
||
# Production image – copy only production dependencies and source code (assumes your code is prebuilt) | ||
FROM base AS release | ||
COPY --from=prod-deps /temp/prod/node_modules ./node_modules | ||
COPY --from=prod-deps /home/app/node_modules ./node_modules | ||
COPY . . | ||
# If you have a build step that does not rely on devDependencies, run it here | ||
CMD ["bun", "start"] |