Turborepo with fking docker shit
Im so fking tired now, im trying to deploy this fking shit from last 10 hours and this bitch is still not getting deployed. it's name must be dickker fuk docker fuk bun.
It was working before but as soon as i added a package and added it as a dependency to my server app (bun+hono) it didnt work. even though its working on my machine.
Heres my dickerfile:
# ⚡ 1. Use Ubuntu Minimal (smaller base image)
FROM ubuntu:22.04 AS builder
ENV DEBIAN_FRONTEND=noninteractive
# Install system dependencies & Bun
RUN apt update && apt install -y curl bash unzip libvips \
&& rm -rf /var/lib/apt/lists/* \
&& curl -fsSL https://bun.sh/install | bash \
&& mv /root/.bun/bin/bun /usr/local/bin/bun
WORKDIR /app
# Copy everything including the packages folder
COPY . .
# Install dependencies (including workspaces)
RUN bun install
# Build **only** the server project
RUN bun run --filter=server build
# ⚡ 3. Use a lightweight runtime image
FROM ubuntu:22.04 AS runner
RUN apt update && apt install -y libvips && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local/bin/bun /usr/local/bin/bun
WORKDIR /app
COPY --from=builder /app/apps/server/dist /app
RUN ls -l /app
# Expose backend port
EXPOSE 3001
# Start the backend
CMD ["bun", "run", "index.js"]

0 Replies