Spaces:
Runtime error
Runtime error
File size: 922 Bytes
a0f1951 873a252 083a8f0 f4821f9 083a8f0 a0f1951 ee59a81 a0f1951 ee59a81 a0f1951 ee59a81 a0f1951 ee59a81 a0f1951 ee59a81 a0f1951 1040e3c c77b784 51d0cdf 73c59a6 ecc8f2a 5978d0d 1040e3c 79218eb 3c47f7b a0f1951 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
FROM node:20-alpine AS builder
RUN apk add --no-cache libc6-compat
WORKDIR /app
# Install dependencies based on the preferred package manager
COPY frontend .
RUN npm i
RUN npm run build
RUN ls -al
FROM python:3.10-slim AS backend
WORKDIR /app
# RUN apt-get update && apt-get install --no-install-recommends -y \
# git ffmpeg curl gnupg \
# && apt-get clean && rm -rf /var/lib/apt/lists/*
# RUN useradd -m -u 1000 user
COPY ./requirements.txt .
RUN pip install --no-cache-dir --upgrade -r /app/requirements.txt
EXPOSE 5000
# USER user
# ENV HOME=/home/user \
# PATH=/home/user/.local/bin:$PATH
WORKDIR /app
COPY --from=builder /app/build ./static
COPY . .
# RUN mkdir blabla
# RUN mkdir blabla/cache
RUN mkdir -p /app/cache/hub/models--suno--bark
RUN chmod u+rwX /app/cache/hub
ENV HF_HOME=/app/cache/
# ENV TRANSFORMERS_CACHE=./cache/
# ENV HF_HOME=blabla/cache/
CMD ["python", "app.py"]
|