|
FROM ghcr.io/open-webui/open-webui:main |
|
|
|
|
|
RUN apt-get update && apt-get install -y python3 python3-pip \ |
|
&& pip3 install --no-cache-dir huggingface_hub \ |
|
&& apt-get clean \ |
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
|
|
COPY sync_data.sh ./ |
|
COPY custom.css custom.js editor.css editor.js /app/build/assets/ |
|
|
|
|
|
RUN sed -i \ |
|
-e '/<\/head>/i <link rel="stylesheet" href="assets/editor.css">' \ |
|
-e '/<\/head>/i <link rel="stylesheet" href="assets/custom.css">' \ |
|
-e '/<\/body>/i <script src="assets/editor.js"></script>' \ |
|
-e '/<\/body>/i <script src="assets/custom.js"></script>' \ |
|
/app/build/index.html \ |
|
&& chmod -R 777 ./data \ |
|
&& chmod -R 777 /app/backend/open_webui/static \ |
|
&& chmod +x sync_data.sh \ |
|
&& sed -i "1r sync_data.sh" ./start.sh |
|
|