From 973f0c85fa3d74b07f13ac8702aa32e307a07ed7 Mon Sep 17 00:00:00 2001 From: Francesco Date: Wed, 18 Feb 2026 06:37:53 +0000 Subject: [PATCH] Fix backend Dockerfile - remove unnecessary build step The backend is designed to run TypeScript directly with Bun, not to build. Updated Dockerfile to skip build step and run src/index.ts directly. --- backend/Dockerfile | 22 +++++++--------------- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/backend/Dockerfile b/backend/Dockerfile index 7fd4ea2..af64bb2 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,28 +1,20 @@ FROM node:20-alpine AS base WORKDIR /app -# Install dependencies -FROM base AS install +# Install Bun RUN npm install -g bun -COPY package.json ./ + +# Install dependencies +COPY package.json bun.lockb* ./ RUN bun install -# Build -FROM base AS build -COPY --from=install /app/node_modules ./node_modules +# Copy source code COPY . . -RUN bun build - -# Production -FROM base AS release -RUN npm install -g bun -COPY --from=install /app/node_modules ./node_modules -COPY --from=build /app/dist ./dist -COPY package.json . ENV NODE_ENV=production ENV PORT=3001 EXPOSE 3001 -CMD ["bun", "run", "start"] +# Run directly from TypeScript source (Bun can execute TypeScript directly) +CMD ["bun", "run", "src/index.ts"]