fffiloni commited on
Commit
24f26a3
·
verified ·
1 Parent(s): 9c03def

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +8 -11
Dockerfile CHANGED
@@ -54,12 +54,16 @@ RUN apt-get update && apt-get install -y \
54
  && dpkg -i cudnn-local-repo-ubuntu2204-9.3.0_1.0-1_amd64.deb \
55
  && cp /var/cudnn-local-repo-ubuntu2204-9.3.0/cudnn-local-*-keyring.gpg /usr/share/keyrings/ \
56
  && apt-get update \
57
- && apt-cache madison libcudnn9 \
58
- && apt-get install -y libcudnn9 \
59
- && apt-get clean \
60
- && rm -rf /var/lib/apt/lists/* \
61
  && rm cudnn-local-repo-ubuntu2204-9.3.0_1.0-1_amd64.deb
62
 
 
 
 
 
 
 
 
 
63
  # Verify CuDNN installation
64
  RUN ldconfig && echo "Testing CuDNN installation..." \
65
  && if [ -f /usr/local/cuda/include/cudnn.h ]; then \
@@ -70,13 +74,6 @@ RUN ldconfig && echo "Testing CuDNN installation..." \
70
  # Switch back to the user
71
  USER user
72
 
73
- # Install Python dependencies
74
- COPY . .
75
- RUN pip install --upgrade pip
76
- RUN pip install -r requirements.txt
77
- RUN pip install gradio
78
-
79
- USER root
80
  # Configure git to trust the directory and set ownership
81
  RUN git config --global --add safe.directory /home/user/app
82
  RUN chown -R user:user /home/user/app
 
54
  && dpkg -i cudnn-local-repo-ubuntu2204-9.3.0_1.0-1_amd64.deb \
55
  && cp /var/cudnn-local-repo-ubuntu2204-9.3.0/cudnn-local-*-keyring.gpg /usr/share/keyrings/ \
56
  && apt-get update \
 
 
 
 
57
  && rm cudnn-local-repo-ubuntu2204-9.3.0_1.0-1_amd64.deb
58
 
59
+ # Check NVIDIA packages installed via pip
60
+ RUN echo "Checking NVIDIA packages:" && pip list | grep nvidia
61
+
62
+ # Install your requirements
63
+ RUN pip install --upgrade pip
64
+ RUN pip install -r requirements.txt
65
+ RUN pip install gradio
66
+
67
  # Verify CuDNN installation
68
  RUN ldconfig && echo "Testing CuDNN installation..." \
69
  && if [ -f /usr/local/cuda/include/cudnn.h ]; then \
 
74
  # Switch back to the user
75
  USER user
76
 
 
 
 
 
 
 
 
77
  # Configure git to trust the directory and set ownership
78
  RUN git config --global --add safe.directory /home/user/app
79
  RUN chown -R user:user /home/user/app