|
FROM ghcr.io/open-webui/open-webui:main |
|
|
|
ENV PORT=7860 |
|
ENV HOST=0.0.0.0 |
|
|
|
USER root |
|
|
|
|
|
COPY sync_webuidb.sh /app/sync_webuidb.sh |
|
COPY requirements.txt /app/requirements.txt |
|
COPY icon.png /app/icon.png |
|
|
|
|
|
RUN chmod -R 777 /app && \ |
|
chmod +x /app/sync_webuidb.sh && \ |
|
pip install --no-cache-dir -r /app/requirements.txt || true |
|
|
|
|
|
RUN for file in /app/open_webui/static/*.png; do \ |
|
[ "$file" != "/app/icon.png" ] && cp /app/icon.png "$file"; \ |
|
done && \ |
|
for svg in /app/open_webui/static/*.svg; do \ |
|
png="${svg%.svg}.png"; \ |
|
[ "$png" != "/app/icon.png" ] && cp /app/icon.png "$png"; \ |
|
done |
|
|
|
EXPOSE 7860 |
|
|
|
|
|
CMD bash -c "/app/sync_webuidb.sh & ./start.sh" |