Spaces:
Sleeping
Sleeping
Uncomment HuggingFace token verification in Dockerfile
Browse files- Enable runtime secret verification for HuggingFace token
- Remove previous comment blocking token check
- Maintain existing Dockerfile security and configuration approach
- Dockerfile +2 -2
Dockerfile
CHANGED
@@ -10,7 +10,7 @@ COPY --chown=user . /app
|
|
10 |
|
11 |
EXPOSE 7860
|
12 |
|
13 |
-
|
14 |
-
|
15 |
|
16 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|
|
|
10 |
|
11 |
EXPOSE 7860
|
12 |
|
13 |
+
RUN --mount=type=secret,id=HUGGINGFACE_TOKEN,mode=0444,required=true \
|
14 |
+
test -f /run/secrets/HUGGINGFACE_TOKEN && echo "Secret exists!"
|
15 |
|
16 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|