initial commit (no RAG server)
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
# minimal backend for deepresearch: browser-use web-ui on :7788
|
||||
FROM python:3.11-slim
|
||||
|
||||
ENV PIP_NO_CACHE_DIR=1 \
|
||||
PYTHONUNBUFFERED=1 \
|
||||
PLAYWRIGHT_BROWSERS_PATH=/ms-playwright \
|
||||
WEBUI_IP=0.0.0.0 \
|
||||
WEBUI_PORT=7788
|
||||
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
git curl ca-certificates xvfb dumb-init \
|
||||
&& rm -rf /var/lib/apt/lists/*;
|
||||
|
||||
# grab upstream repo
|
||||
WORKDIR /opt
|
||||
RUN git clone --depth=1 https://github.com/browser-use/web-ui.git
|
||||
|
||||
# create app user with uid=1000 to match compose
|
||||
RUN useradd -u 1000 -ms /bin/bash appuser;
|
||||
|
||||
WORKDIR /opt/web-ui
|
||||
|
||||
# python deps + playwright browsers
|
||||
RUN pip install --upgrade pip \
|
||||
&& pip install -r requirements.txt \
|
||||
&& python -m playwright install chromium --with-deps;
|
||||
|
||||
# prepare writable paths the app expects
|
||||
RUN mkdir -p /opt/web-ui/tmp /data && chown -R appuser:appuser /opt/web-ui /data
|
||||
|
||||
USER appuser
|
||||
|
||||
# copy default env
|
||||
COPY .env .env
|
||||
|
||||
EXPOSE 7788
|
||||
HEALTHCHECK --interval=30s --timeout=5s --retries=5 \
|
||||
CMD python -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:7788').read()" || exit 1
|
||||
|
||||
ENTRYPOINT ["dumb-init", "--"]
|
||||
CMD ["python", "webui.py", "--ip", "0.0.0.0", "--port", "7788"]
|
||||
Reference in New Issue
Block a user