Spaces:
Runtime error
Runtime error
Upload folder using huggingface_hub
Browse files- Dockerfile +17 -5
Dockerfile
CHANGED
@@ -1,4 +1,17 @@
|
|
1 |
-
FROM cgr.dev/chainguard/wolfi-base:latest
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
|
3 |
ENV GRADIO_SERVER_PORT=7860 \
|
4 |
GRADIO_SERVER_NAME=0.0.0.0 \
|
@@ -6,15 +19,14 @@ ENV GRADIO_SERVER_PORT=7860 \
|
|
6 |
PATH=/home/nonroot/.local/bin:$PATH
|
7 |
|
8 |
# skipcq: DOK-DL3018
|
9 |
-
RUN apk add --no-cache curl
|
10 |
|
11 |
USER nonroot
|
12 |
|
13 |
-
RUN --mount=from=ghcr.io/astral-sh/uv,source=/uv,target=/bin/uv \
|
14 |
-
uv tool install vocalizr
|
15 |
-
|
16 |
WORKDIR /home/nonroot
|
17 |
|
|
|
|
|
18 |
EXPOSE ${GRADIO_SERVER_PORT}
|
19 |
|
20 |
CMD ["vocalizr"]
|
|
|
1 |
+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:1fd981aa0bcefd8da87ce55a9ae907862fcb6835c658fdb284867117fb0268ce AS builder
|
2 |
+
|
3 |
+
COPY --from=ghcr.io/astral-sh/uv:latest@sha256:8101ad825250a114e7bef89eefaa73c31e34e10ffbe5aff01562740bac97553c \
|
4 |
+
/uv /uvx /usr/bin/
|
5 |
+
|
6 |
+
# skipcq: DOK-DL3018
|
7 |
+
RUN apk add --no-cache build-base git
|
8 |
+
|
9 |
+
USER nonroot
|
10 |
+
|
11 |
+
RUN --mount=type=cache,target=/root/.cache/uv \
|
12 |
+
uv tool install git+https://github.com/AlphaSphereDotAI/vocalizr
|
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 \
|
|
|
19 |
PATH=/home/nonroot/.local/bin:$PATH
|
20 |
|
21 |
# skipcq: DOK-DL3018
|
22 |
+
RUN apk add --no-cache curl libstdc++
|
23 |
|
24 |
USER nonroot
|
25 |
|
|
|
|
|
|
|
26 |
WORKDIR /home/nonroot
|
27 |
|
28 |
+
COPY --from=builder --chown=nonroot:nonroot --chmod=755 /home/nonroot/.local/ /home/nonroot/.local/
|
29 |
+
|
30 |
EXPOSE ${GRADIO_SERVER_PORT}
|
31 |
|
32 |
CMD ["vocalizr"]
|