Spaces:
Running
Running
coyotte508
commited on
Commit
·
3f70154
1
Parent(s):
4c274af
remove git & try again
Browse files- Dockerfile +1 -2
- build.sh +2 -2
Dockerfile
CHANGED
|
@@ -5,8 +5,6 @@ FROM node:22-bullseye-slim
|
|
| 5 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 6 |
python3 \
|
| 7 |
python3-pip \
|
| 8 |
-
git \
|
| 9 |
-
git-lfs \
|
| 10 |
&& rm -rf /var/lib/apt/lists/*
|
| 11 |
|
| 12 |
RUN git lfs install
|
|
@@ -18,6 +16,7 @@ RUN corepack enable \
|
|
| 18 |
|
| 19 |
# Install huggingface_hub and huggingface_hub[cli]
|
| 20 |
RUN pip install -U "huggingface_hub"
|
|
|
|
| 21 |
|
| 22 |
# Define a working directory
|
| 23 |
WORKDIR /app
|
|
|
|
| 5 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 6 |
python3 \
|
| 7 |
python3-pip \
|
|
|
|
|
|
|
| 8 |
&& rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
RUN git lfs install
|
|
|
|
| 16 |
|
| 17 |
# Install huggingface_hub and huggingface_hub[cli]
|
| 18 |
RUN pip install -U "huggingface_hub"
|
| 19 |
+
USER 1000
|
| 20 |
|
| 21 |
# Define a working directory
|
| 22 |
WORKDIR /app
|
build.sh
CHANGED
|
@@ -10,8 +10,8 @@ if [ -z "$HF_TOKEN" ] || [ -z "$HF_SPACE_NAME" ] || [ -z "$BUILD_COMMAND" ] || [
|
|
| 10 |
fi
|
| 11 |
|
| 12 |
# Download the space
|
| 13 |
-
git clone --depth 1 https://:[email protected]/spaces/$HF_SPACE_NAME space
|
| 14 |
-
|
| 15 |
|
| 16 |
# Change directory to the space's directory
|
| 17 |
cd space
|
|
|
|
| 10 |
fi
|
| 11 |
|
| 12 |
# Download the space
|
| 13 |
+
# git clone --depth 1 https://:[email protected]/spaces/$HF_SPACE_NAME space
|
| 14 |
+
huggingface-cli download $HF_SPACE_NAME --repo-type space --local-dir space --token $HF_TOKEN
|
| 15 |
|
| 16 |
# Change directory to the space's directory
|
| 17 |
cd space
|