Update Dockerfile
Browse files- Dockerfile +6 -6
Dockerfile
CHANGED
@@ -8,20 +8,20 @@ USER root
|
|
8 |
# Sao chép các file cần thiết
|
9 |
COPY sync_webuidb.sh /app/sync_webuidb.sh
|
10 |
COPY requirements.txt /app/requirements.txt
|
11 |
-
COPY icon.png /app/static/icon.png
|
12 |
|
13 |
# Cấp quyền và cài requirements
|
14 |
RUN chmod -R 777 /app && \
|
15 |
chmod +x /app/sync_webuidb.sh && \
|
16 |
pip install --no-cache-dir -r /app/requirements.txt || true
|
17 |
|
18 |
-
# Ghi đè
|
19 |
-
RUN for file in /app/static/*.png; do \
|
20 |
-
[ "$file" != "/app/static/icon.png" ] && cp /app/static/icon.png "$file"; \
|
21 |
done && \
|
22 |
-
for svg in /app/static/*.svg; do \
|
23 |
png="${svg%.svg}.png"; \
|
24 |
-
[ "$png" != "/app/static/icon.png" ] && cp /app/static/icon.png "$png"; \
|
25 |
done
|
26 |
|
27 |
EXPOSE 7860
|
|
|
8 |
# Sao chép các file cần thiết
|
9 |
COPY sync_webuidb.sh /app/sync_webuidb.sh
|
10 |
COPY requirements.txt /app/requirements.txt
|
11 |
+
COPY icon.png /app/open_webui/static/icon.png
|
12 |
|
13 |
# Cấp quyền và cài requirements
|
14 |
RUN chmod -R 777 /app && \
|
15 |
chmod +x /app/sync_webuidb.sh && \
|
16 |
pip install --no-cache-dir -r /app/requirements.txt || true
|
17 |
|
18 |
+
# Ghi đè các file icon .png và chuyển svg → png, bỏ qua chính icon.png
|
19 |
+
RUN for file in /app/open_webui/static/*.png; do \
|
20 |
+
[ "$file" != "/app/open_webui/static/icon.png" ] && cp /app/open_webui/static/icon.png "$file"; \
|
21 |
done && \
|
22 |
+
for svg in /app/open_webui/static/*.svg; do \
|
23 |
png="${svg%.svg}.png"; \
|
24 |
+
[ "$png" != "/app/open_webui/static/icon.png" ] && cp /app/open_webui/static/icon.png "$png"; \
|
25 |
done
|
26 |
|
27 |
EXPOSE 7860
|