mirror of
https://github.com/harivansh-afk/sandbox-agent.git
synced 2026-04-15 06:04:43 +00:00
fix: update website Dockerfile for monorepo context
This commit is contained in:
parent
9d350feac8
commit
bc943af447
1 changed files with 14 additions and 5 deletions
|
|
@ -1,13 +1,22 @@
|
|||
FROM node:22-alpine AS build
|
||||
WORKDIR /app
|
||||
RUN npm install -g pnpm
|
||||
COPY package.json pnpm-lock.yaml* ./
|
||||
RUN pnpm install
|
||||
COPY . .
|
||||
RUN pnpm build
|
||||
|
||||
# Copy package files for all workspaces
|
||||
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml ./
|
||||
COPY frontend/packages/website/package.json ./frontend/packages/website/
|
||||
|
||||
# Install dependencies
|
||||
RUN pnpm install --filter @sandbox-agent/website...
|
||||
|
||||
# Copy website source
|
||||
COPY frontend/packages/website ./frontend/packages/website
|
||||
|
||||
# Build
|
||||
RUN pnpm --filter @sandbox-agent/website build
|
||||
|
||||
FROM caddy:alpine
|
||||
COPY --from=build /app/dist /srv
|
||||
COPY --from=build /app/frontend/packages/website/dist /srv
|
||||
RUN cat > /etc/caddy/Caddyfile <<'EOF'
|
||||
:80 {
|
||||
root * /srv
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue