dockerfix-5
This commit is contained in:
11
Dockerfile
11
Dockerfile
@@ -29,6 +29,8 @@ RUN uv sync --frozen --no-install-project
|
|||||||
|
|
||||||
# 🏗️ Frontend build (build with all dependencies)
|
# 🏗️ Frontend build (build with all dependencies)
|
||||||
COPY . .
|
COPY . .
|
||||||
|
# Install local package in builder stage
|
||||||
|
RUN uv sync --frozen --no-editable
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
# 🚀 Production stage
|
# 🚀 Production stage
|
||||||
@@ -46,14 +48,13 @@ RUN mkdir -p /app/.cache/huggingface && chmod 755 /app/.cache/huggingface
|
|||||||
ENV TRANSFORMERS_CACHE=/app/.cache/huggingface
|
ENV TRANSFORMERS_CACHE=/app/.cache/huggingface
|
||||||
ENV HF_HOME=/app/.cache/huggingface
|
ENV HF_HOME=/app/.cache/huggingface
|
||||||
|
|
||||||
# 📦 Copy compiled Python environment from builder
|
# 🚀 Application code (rebuilt on any code change)
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
# 📦 Copy compiled Python environment from builder (includes all dependencies + local package)
|
||||||
COPY --from=builder /app/.venv /app/.venv
|
COPY --from=builder /app/.venv /app/.venv
|
||||||
ENV PATH="/app/.venv/bin:$PATH"
|
ENV PATH="/app/.venv/bin:$PATH"
|
||||||
|
|
||||||
# 🚀 Application code and final setup (rebuilt on any code change)
|
|
||||||
COPY . .
|
|
||||||
RUN uv sync --frozen --no-editable --no-build
|
|
||||||
|
|
||||||
# 📦 Copy built frontend from builder stage
|
# 📦 Copy built frontend from builder stage
|
||||||
COPY --from=builder /app/dist ./dist
|
COPY --from=builder /app/dist ./dist
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "discours-core"
|
name = "discours-core"
|
||||||
version = "0.9.18"
|
version = "0.9.20"
|
||||||
description = "Core backend for Discours.io platform"
|
description = "Core backend for Discours.io platform"
|
||||||
authors = [
|
authors = [
|
||||||
{name = "Tony Rewin", email = "tonyrewin@yandex.ru"}
|
{name = "Tony Rewin", email = "tonyrewin@yandex.ru"}
|
||||||
|
|||||||
Reference in New Issue
Block a user