Spaces:
Build error
Build error
Upload folder using huggingface_hub
Browse files- .gitignore +4 -17
- Dockerfile +17 -32
.gitignore
CHANGED
@@ -1,17 +1,4 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
.ruff_cache/
|
6 |
-
.venv/
|
7 |
-
logs/
|
8 |
-
results/
|
9 |
-
ckpts/
|
10 |
-
Anitalker/
|
11 |
-
outputs/
|
12 |
-
|
13 |
-
.github/
|
14 |
-
.trunk/
|
15 |
-
.idea/
|
16 |
-
renovate.json
|
17 |
-
.deepsource.toml
|
|
|
1 |
+
*
|
2 |
+
!.gitignore
|
3 |
+
!README.md
|
4 |
+
!Dockerfile
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Dockerfile
CHANGED
@@ -1,46 +1,31 @@
|
|
1 |
-
FROM
|
2 |
|
3 |
-
|
|
|
4 |
|
5 |
-
|
6 |
-
|
7 |
-
UV_PYTHON_DOWNLOADS=0
|
8 |
|
9 |
-
|
10 |
-
|
11 |
-
WORKDIR /app
|
12 |
-
|
13 |
-
RUN --mount=type=cache,target=/root/.cache/uv \
|
14 |
-
--mount=type=bind,source=uv.lock,target=uv.lock \
|
15 |
-
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
|
16 |
-
--mount=type=bind,source=README.md,target=README.md \
|
17 |
-
uv sync --no-install-project --no-dev --locked --no-editable
|
18 |
-
|
19 |
-
COPY . /app
|
20 |
|
21 |
RUN --mount=type=cache,target=/root/.cache/uv \
|
22 |
-
uv
|
23 |
-
|
24 |
-
FROM python:3.10-slim AS production
|
25 |
|
26 |
-
|
27 |
|
28 |
ENV GRADIO_SERVER_PORT=7860 \
|
29 |
-
GRADIO_SERVER_NAME=0.0.0.0
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
apt-get install -qq -y --no-install-recommends espeak-ng ffmpeg && \
|
35 |
-
apt-get clean -qq && \
|
36 |
-
rm -rf /var/lib/apt/lists/*
|
37 |
|
38 |
-
|
39 |
|
40 |
-
|
41 |
|
42 |
-
|
43 |
|
44 |
EXPOSE ${GRADIO_SERVER_PORT}
|
45 |
|
46 |
-
CMD ["
|
|
|
1 |
+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:1fd981aa0bcefd8da87ce55a9ae907862fcb6835c658fdb284867117fb0268ce AS builder
|
2 |
|
3 |
+
COPY --from=ghcr.io/astral-sh/uv:latest@sha256:b05b3d61eb2b264ed785265b71155738a0d3d382ea0699e048d4b36f90b88788 \
|
4 |
+
/uv /uvx /usr/bin/
|
5 |
|
6 |
+
# skipcq: DOK-DL3018
|
7 |
+
RUN apk add --no-cache git build-base
|
|
|
8 |
|
9 |
+
USER nonroot
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
|
11 |
RUN --mount=type=cache,target=/root/.cache/uv \
|
12 |
+
uv tool install git+https://github.com/AlphaSphereDotAI/visualizr
|
|
|
|
|
13 |
|
14 |
+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:1fd981aa0bcefd8da87ce55a9ae907862fcb6835c658fdb284867117fb0268ce AS production
|
15 |
|
16 |
ENV GRADIO_SERVER_PORT=7860 \
|
17 |
+
GRADIO_SERVER_NAME=0.0.0.0 \
|
18 |
+
PATH=/home/nonroot/.local/bin:$PATH
|
19 |
+
|
20 |
+
# skipcq: DOK-DL3018
|
21 |
+
RUN apk add --no-cache curl #libstdc++
|
|
|
|
|
|
|
22 |
|
23 |
+
USER nonroot
|
24 |
|
25 |
+
WORKDIR /home/nonroot
|
26 |
|
27 |
+
COPY --from=builder --chown=nonroot:nonroot --chmod=555 /home/nonroot/.local/ /home/nonroot/.local/
|
28 |
|
29 |
EXPOSE ${GRADIO_SERVER_PORT}
|
30 |
|
31 |
+
CMD ["visualizr"]
|