5d29f03d50
- Moved boosapi-rs/* to repo root - Deleted all Node.js source (src/server/, src/web/, scripts/) - Deleted node_modules, package.json, tsconfig, vite.config - Updated .gitignore and AGENTS.md for Rust-only stack - Fixed static file path for frontend dist/web/ - Dockerfile stays the same (already Rust-only) - Kept dist/web/ for Rust static serving
19 lines
575 B
Docker
19 lines
575 B
Docker
# Build stage
|
|
FROM rust:1.85-slim-bookworm AS builder
|
|
WORKDIR /app
|
|
RUN apt-get update && apt-get install -y pkg-config libssl-dev
|
|
COPY Cargo.toml Cargo.lock ./
|
|
RUN mkdir src && echo "fn main() {}" > src/main.rs
|
|
RUN cargo build --release 2>/dev/null || true
|
|
COPY . .
|
|
RUN cargo build --release
|
|
|
|
# Runtime stage
|
|
FROM debian:bookworm-slim
|
|
RUN apt-get update && apt-get install -y ca-certificates && rm -rf /var/lib/apt/lists/*
|
|
WORKDIR /app
|
|
COPY --from=builder /app/target/release/boosapi /app/
|
|
COPY --from=builder /app/migrations /app/migrations
|
|
EXPOSE 4000
|
|
CMD ["/app/boosapi"]
|