File size: 648 Bytes
d8c858d ac3be5b 698a0e5 ac3be5b 5d2bd4d d8c858d 5d2bd4d d8c858d 5d2bd4d 5c9430c 5d2bd4d d8c858d 5d2bd4d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
FROM ghcr.io/open-webui/open-webui:main
ENV ENV=production
ENV WEBUI_AUTH=false
ENV OPENAI_API_BASE_URL=https://api.deepinfra.com/v1/openai
ENV OPENAI_API_KEY=OPENAI_API_KEY
# Create a non-root user
RUN useradd -m -u 1000 webuser
# Set the working directory
WORKDIR /app
# Create necessary directories and set permissions
RUN mkdir -p /app/backend/data && \
chown -R webuser:webuser /app
# Switch to the non-root user
USER webuser
# Set environment variables
ENV HOME=/home/webuser \
PATH=/home/webuser/.local/bin:$PATH \
WEBUI_SECRET_KEY=/app/backend/data/.webui_secret_key
# Run the start script
CMD ["/app/backend/start.sh"]
|