File tree Expand file tree Collapse file tree 3 files changed +17
-10
lines changed
comps/dataprep/redis/llama_index/docker Expand file tree Collapse file tree 3 files changed +17
-10
lines changed Original file line number Diff line number Diff line change 3939 | grep 'comps/' | grep -vE '*.md|*.txt|comps/cores')" || true
4040 services=$(printf '%s\n' "${changed_files[@]}" | cut -d'/' -f2 | grep -vE '*.py' | sort -u)
4141 path_level_1=("asr" "tts")
42- path_level_3=("llms ")
42+ path_level_3=("llms_summarization" "llms_text-generation" "dataprep_redis ")
4343 run_matrix="{\"include\":["
4444 for service in ${services}; do
4545 hardware="gaudi" # default hardware, set based on the changed files
4848 else
4949 vendors=$(printf '%s\n' "${changed_files[@]}" | grep ${service} | cut -d'/' -f3 | grep -vE '*.py' | sort -u)
5050 for vendor in ${vendors}; do
51- if [[ "${path_level_3[@]}" =~ "${service}" ]]; then
51+ if [[ "${path_level_3[@]}" =~ "${service}_${vendor} " ]]; then
5252 sub_vendors=$(printf '%s\n' "${changed_files[@]}" | grep ${service} | grep ${vendor} | cut -d'/' -f4 | grep -vE '*.py' | sort -u)
5353 for sub_vendor in ${sub_vendors}; do
5454 run_matrix="${run_matrix}{\"service\":\"${service}_${vendor}_${sub_vendor}\",\"hardware\":\"${hardware}\"},"
Original file line number Diff line number Diff line change 22# Copyright (C) 2024 Intel Corporation
33# SPDX-License-Identifier: Apache-2.0
44
5- FROM ubuntu:22.04
5+ FROM python:3.11-slim
6+
7+ ENV LANG C.UTF-8
68
79RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
10+ build-essential \
811 libgl1-mesa-glx \
912 libjemalloc-dev \
10- vim \
11- python3 \
12- python3-pip
13+ vim
1314
1415RUN useradd -m -s /bin/bash user && \
1516 mkdir -p /home/user && \
@@ -19,12 +20,18 @@ USER user
1920
2021COPY comps /home/user/comps
2122
22- RUN pip install --no-cache-dir --upgrade pip && \
23+ RUN pip install --no-cache-dir --upgrade pip setuptools && \
2324 pip install --no-cache-dir -r /home/user/comps/dataprep/redis/llama_index/requirements.txt
2425
2526ENV PYTHONPATH=$PYTHONPATH:/home/user
2627
28+ USER root
29+
30+ RUN mkdir -p /home/user/comps/dataprep/redis/llama_index/uploaded_files && chown -R user /home/user/comps/dataprep/redis/llama_index/uploaded_files
31+
32+ USER user
33+
2734WORKDIR /home/user/comps/dataprep/redis/llama_index
2835
29- ENTRYPOINT ["python3 " , "prepare_doc_redis.py" ]
36+ ENTRYPOINT ["python " , "prepare_doc_redis.py" ]
3037
Original file line number Diff line number Diff line change @@ -16,14 +16,14 @@ function build_docker_images() {
1616
1717function start_service() {
1818 docker run -d --name=" test-comps-dataprep-redis" -e http_proxy=$http_proxy -e https_proxy=$https_proxy -p 6379:6379 -p 8001:8001 --ipc=host redis/redis-stack:7.2.0-v9
19- dataprep_service_port=5011
19+ dataprep_service_port=5012
2020 REDIS_URL=" redis://${ip_address} :6379"
2121 docker run -d --name=" test-comps-dataprep-redis-server" -e http_proxy=$http_proxy -e https_proxy=$https_proxy -e REDIS_URL=$REDIS_URL -p ${dataprep_service_port} :6007 --ipc=host opea/dataprep-redis:comps
2222 sleep 1m
2323}
2424
2525function validate_microservice() {
26- dataprep_service_port=5011
26+ dataprep_service_port=5012
2727 URL=" http://${ip_address} :$dataprep_service_port /v1/dataprep"
2828 echo " Deep learning is a subset of machine learning that utilizes neural networks with multiple layers to analyze various levels of abstract data representations. It enables computers to identify patterns and make decisions with minimal human intervention by learning from large amounts of data." > ./dataprep_file.txt
2929 HTTP_STATUS=$( curl -s -o /dev/null -w " %{http_code}" -X POST -F ' files=@./dataprep_file.txt' -H ' Content-Type: multipart/form-data' " $URL " )
You can’t perform that action at this time.
0 commit comments