From a7d2d75bdafe25e313eb0d5e79004609b4cfde8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8D=9A=E9=80=9A?= Date: Thu, 14 May 2026 11:13:11 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4dockerfile=20backup?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/Dockerfile_BACKUP_79990 | 75 --------------------------------- 1 file changed, 75 deletions(-) delete mode 100644 backend/Dockerfile_BACKUP_79990 diff --git a/backend/Dockerfile_BACKUP_79990 b/backend/Dockerfile_BACKUP_79990 deleted file mode 100644 index dd771f07..00000000 --- a/backend/Dockerfile_BACKUP_79990 +++ /dev/null @@ -1,75 +0,0 @@ -<<<<<<< HEAD -FROM python:3.12-slim-bookworm - -WORKDIR /app - -# Oracle Instant Client runtime dependencies for thick mode. -# `libaio1` is available on Debian bookworm, while newer variants may expose `libaio1t64`. -RUN apt-get update \ - && (apt-get install -y --no-install-recommends libaio1 libnsl2 \ - || apt-get install -y --no-install-recommends libaio1t64 libnsl2) \ - && rm -rf /var/lib/apt/lists/* - -# Install Python dependencies -COPY backend/requirements.txt . -RUN pip install --no-cache-dir -r requirements.txt -======= -ARG PYTHON_BASE_IMAGE=python:3.12-slim -FROM ${PYTHON_BASE_IMAGE} - -ARG APT_MIRROR=https://mirrors.aliyun.com -ARG PIP_INDEX_URL=https://mirrors.aliyun.com/pypi/simple -ARG PIP_EXTRA_INDEX_URL - -WORKDIR /app - -RUN set -eux; \ - if [ -f /etc/apt/sources.list.d/debian.sources ]; then \ - sed -i "s|http://deb.debian.org/debian|${APT_MIRROR}/debian|g" /etc/apt/sources.list.d/debian.sources; \ - sed -i "s|http://deb.debian.org/debian-security|${APT_MIRROR}/debian-security|g" /etc/apt/sources.list.d/debian.sources; \ - fi; \ - if [ -f /etc/apt/sources.list ]; then \ - sed -i "s|http://deb.debian.org/debian|${APT_MIRROR}/debian|g" /etc/apt/sources.list; \ - sed -i "s|http://deb.debian.org/debian-security|${APT_MIRROR}/debian-security|g" /etc/apt/sources.list; \ - fi; \ - apt-get update && apt-get install -y \ - libgl1 \ - libglib2.0-0 \ - libxcb1 \ - libx11-6 \ - libxext6 \ - libreoffice \ - fonts-noto-cjk \ - && rm -rf /var/lib/apt/lists/* - -# Install Python dependencies -COPY requirements.txt . -RUN set -eux; \ - PIP_ARGS="--no-cache-dir --retries 10 --timeout 60"; \ - if [ -n "${PIP_INDEX_URL:-}" ]; then \ - PIP_ARGS="$PIP_ARGS --index-url ${PIP_INDEX_URL}"; \ - fi; \ - if [ -n "${PIP_EXTRA_INDEX_URL:-}" ]; then \ - PIP_ARGS="$PIP_ARGS --extra-index-url ${PIP_EXTRA_INDEX_URL}"; \ - fi; \ - pip install $PIP_ARGS -r requirements.txt && \ - pip uninstall -y opencv-python && \ - pip install $PIP_ARGS opencv-python-headless && \ - python -c "import networkx, openpyxl" ->>>>>>> runny&xinxin - -# Copy backend code and the Text2SQL schema required at runtime -COPY backend/ . -RUN mkdir -p /app/docs -COPY docs/(表+字段).md /app/docs/(表+字段).md -ENV ORACLE_HOME=/app/oracle_client/instantclient_19_31 -ENV LD_LIBRARY_PATH=/app/oracle_client/instantclient_19_31:/app/oracle_client:${LD_LIBRARY_PATH} - - -# Expose port 5000 -EXPOSE 5000 - -# Start Gunicorn -# Using the config file we created earlier -CMD ["gunicorn", "-c", "deploy/gunicorn_config.py", "run:app"] -