Commit
·
9b4c197
1
Parent(s):
1c0efea
is it simpler?
Browse files- Dockerfile +7 -15
Dockerfile
CHANGED
@@ -9,29 +9,21 @@ RUN apt-get update && \
|
|
9 |
apt-get clean && \
|
10 |
rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
-
#
|
13 |
-
|
14 |
-
chmod -R 777 /.cache /root/.cache
|
15 |
|
16 |
# Install required dependencies
|
17 |
RUN pip install --upgrade pip
|
18 |
-
|
19 |
-
# Copy requirements first for better caching
|
20 |
-
COPY requirements.txt .
|
21 |
RUN pip install --no-cache-dir -r requirements.txt
|
22 |
|
23 |
-
# Copy application files
|
24 |
-
COPY . .
|
25 |
-
|
26 |
# Make sft script executable
|
27 |
-
COPY sft.py /usr/local/bin/sft
|
28 |
RUN chmod +x /usr/local/bin/sft
|
29 |
|
30 |
-
# Set
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
ENV
|
35 |
|
36 |
# Start gradio application
|
37 |
EXPOSE 7860
|
|
|
9 |
apt-get clean && \
|
10 |
rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
+
# Copy everything and set permissions
|
13 |
+
COPY . .
|
|
|
14 |
|
15 |
# Install required dependencies
|
16 |
RUN pip install --upgrade pip
|
|
|
|
|
|
|
17 |
RUN pip install --no-cache-dir -r requirements.txt
|
18 |
|
|
|
|
|
|
|
19 |
# Make sft script executable
|
|
|
20 |
RUN chmod +x /usr/local/bin/sft
|
21 |
|
22 |
+
# Set full write permissions for current directory
|
23 |
+
RUN chmod -R 777 .
|
24 |
+
|
25 |
+
# Set cache environment variables to use current directory
|
26 |
+
ENV XDG_CACHE_HOME=./cache
|
27 |
|
28 |
# Start gradio application
|
29 |
EXPOSE 7860
|