udayl commited on
Commit
113d9e8
·
1 Parent(s): f1a5f11
Files changed (1) hide show
  1. Dockerfile +5 -5
Dockerfile CHANGED
@@ -11,7 +11,8 @@ RUN apt-get update && apt-get install -y \
11
  mkdir -p /tmp/huggingface/gradio/frpc && \
12
  curl -L -o /tmp/huggingface/gradio/frpc/frpc_linux_amd64_v0.3 \
13
  https://cdn-media.huggingface.co/frpc-gradio-0.3/frpc_linux_amd64 && \
14
- chmod +x /tmp/huggingface/gradio/frpc/frpc_linux_amd64_v0.3
 
15
 
16
  # Copy requirements and install Python dependencies
17
  COPY requirements.txt .
@@ -22,12 +23,11 @@ COPY . .
22
 
23
  # Set environment variables
24
  ENV PYTHONUNBUFFERED=1 \
25
- HF_HOME=/tmp/huggingface
26
-
27
- RUN chown -R $(whoami) /tmp/huggingface
28
 
29
  # Expose port
30
  EXPOSE 7860
31
 
32
- # Command to run the application
33
  CMD ["python", "gradio_app.py"]
 
11
  mkdir -p /tmp/huggingface/gradio/frpc && \
12
  curl -L -o /tmp/huggingface/gradio/frpc/frpc_linux_amd64_v0.3 \
13
  https://cdn-media.huggingface.co/frpc-gradio-0.3/frpc_linux_amd64 && \
14
+ chmod +x /tmp/huggingface/gradio/frpc/frpc_linux_amd64_v0.3 && \
15
+ chmod -R 777 /tmp/huggingface
16
 
17
  # Copy requirements and install Python dependencies
18
  COPY requirements.txt .
 
23
 
24
  # Set environment variables
25
  ENV PYTHONUNBUFFERED=1 \
26
+ HF_HOME=/tmp/huggingface \
27
+ TRANSFORMERS_CACHE=/tmp/huggingface
 
28
 
29
  # Expose port
30
  EXPOSE 7860
31
 
32
+ # Run the app
33
  CMD ["python", "gradio_app.py"]