21 Star 72 Fork 73

openEuler/openeuler-docker-images
关闭

加入 Gitee
与超过 1400万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Dockerfile 1.42 KB
一键复制 编辑 原始数据 按行查看 历史
zhihang 提交于 2025-07-26 17:09 +08:00 . update SearchQnA
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
ARG BASE=openeuler/python:3.11.13-oe2403lts
ARG VERSION=v1.2
# Stage 1: base setup used by other stages
FROM $BASE AS base
# get security updates
RUN yum update -y && \
yum install -y \
shadow && \
yum clean all && \
rm -rf /var/cache/yum
ENV HOME=/home/user
RUN useradd -m -s /bin/bash user && \
mkdir -p $HOME && \
chown -R user $HOME
WORKDIR $HOME
# Stage 2: latest GenAIComps sources
FROM base AS git
ARG VERSION
RUN yum update -y && \
yum install -y git && \
yum clean all && \
rm -rf /var/cache/yum
ARG GENAICOMPS_REPO=https://github.com/opea-project/GenAIComps.git
RUN git clone -b $VERSION $GENAICOMPS_REPO
ARG GENAIEXAMPLES_REPO=https://github.com/opea-project/GenAIExamples.git
RUN git clone -b $VERSION $GENAIEXAMPLES_REPO
# Stage 3: common layer shared by services using GenAIComps
FROM base AS comps-base
# copy just relevant parts
COPY --from=git $HOME/GenAIComps/comps $HOME/GenAIComps/comps
COPY --from=git $HOME/GenAIComps/*.* $HOME/GenAIComps/LICENSE $HOME/GenAIComps/
COPY --from=git $HOME/GenAIExamples/SearchQnA/searchqna.py $HOME/searchqna.py
WORKDIR $HOME/GenAIComps
RUN pip install --no-cache-dir --upgrade pip setuptools && \
pip install --no-cache-dir -r $HOME/GenAIComps/requirements.txt
WORKDIR $HOME
ENV PYTHONPATH=$PYTHONPATH:$HOME/GenAIComps
USER user
ENTRYPOINT ["python", "searchqna.py"]
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/openeuler/openeuler-docker-images.git
git@gitee.com:openeuler/openeuler-docker-images.git
openeuler
openeuler-docker-images
openeuler-docker-images
master

搜索帮助