Skip to content

Commit 8934766

Browse files
committed
update for sql agent
Signed-off-by: wwanrif <wan.abdul.hakim.b.wan.arif@intel.com>
1 parent 72d8bff commit 8934766

File tree

5 files changed

+38
-37
lines changed

5 files changed

+38
-37
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
test-results/
22
**.log
3-
**/report.html
3+
**/report.html
4+
docker-compose

setup-scripts/setup-genai-studio/playbooks/deploy-studio.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
MYSQL_HOST: "{{ mysql_host }}"
6363

6464
- name: Wait for all pods to be ready in studio namespace
65-
shell: kubectl wait --for=condition=ready pod --all --namespace=studio --timeout=300s
65+
shell: kubectl wait --for=condition=ready pod --all --namespace=studio --timeout=420s
6666
register: pod_ready_check
6767
failed_when: pod_ready_check.rc != 0
6868
changed_when: false

studio-backend/app/templates/app/app.compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@ app-nginx:
4848
- BACKEND_SERVICE_IP=${public_host_ip}
4949
- BACKEND_SERVICE_PORT=8888
5050
- DATAPREP_SERVICE_IP=${public_host_ip}
51-
- DATAPREP_SERVICE_PORT=6007
51+
- DATAPREP_SERVICE_PORT=${prepare_doc_redis_prep_0_port}
5252
ipc: host
5353
restart: always

studio-backend/app/templates/microsvc-composes/sql-agent.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
container_name: "{{endpoint}}"
44
ports:
55
- "{{port_key}}:9096"
6-
volumes:
7-
- ./agent-tools/:/home/user/tools/
6+
# volumes:
7+
# - ./agent-tools/:/home/user/tools/
88
ipc: host
99
environment:
1010
ip_address: ${public_host_ip}

studio-backend/app/templates/microsvc-manifests/sql-agent.yaml

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -47,37 +47,37 @@ spec:
4747
labels:
4848
app: "{endpoint}"
4949
spec:
50-
initContainers:
51-
- name: agentqna-tools
52-
image: curlimages/curl:latest
53-
command: ["/bin/sh", "-c"]
54-
args:
55-
- |
56-
TOOLS_GIT_URL="https://github.com/opea-project/GenAIStudio/tree/main/studio-backend/app/templates/tools"
57-
OWNER=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/([^/]+)/([^/]+)/tree/([^/]+)/.*|\1|')
58-
REPO=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/([^/]+)/([^/]+)/tree/([^/]+)/.*|\2|')
59-
BRANCH=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/[^/]+/[^/]+/tree/([^/]+)/.*|\1|')
60-
TOOLS_DIR=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/[^/]+/[^/]+/tree/[^/]+/(.*?)/?$|\1|')
61-
if [[ "${TOOLS_DIR: -1}" == "/" ]]; then TOOLS_DIR="${TOOLS_DIR%/}"; fi
62-
DOWNLOAD_URL="https://codeload.github.com/${OWNER}/${REPO}/tar.gz/${BRANCH}"
63-
curl "${DOWNLOAD_URL}" | tar -xz --strip-components=5 -C /home/user/tools/ "${REPO}-${BRANCH}/${TOOLS_DIR}"
50+
# initContainers:
51+
# - name: agentqna-tools
52+
# image: curlimages/curl:latest
53+
# command: ["/bin/sh", "-c"]
54+
# args:
55+
# - |
56+
# TOOLS_GIT_URL="https://github.com/opea-project/GenAIStudio/tree/main/studio-backend/app/templates/tools"
57+
# OWNER=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/([^/]+)/([^/]+)/tree/([^/]+)/.*|\1|')
58+
# REPO=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/([^/]+)/([^/]+)/tree/([^/]+)/.*|\2|')
59+
# BRANCH=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/[^/]+/[^/]+/tree/([^/]+)/.*|\1|')
60+
# TOOLS_DIR=$(echo ${TOOLS_GIT_URL} | sed -E 's|https://github.com/[^/]+/[^/]+/tree/[^/]+/(.*?)/?$|\1|')
61+
# if [[ "${TOOLS_DIR: -1}" == "/" ]]; then TOOLS_DIR="${TOOLS_DIR%/}"; fi
62+
# DOWNLOAD_URL="https://codeload.github.com/${OWNER}/${REPO}/tar.gz/${BRANCH}"
63+
# curl "${DOWNLOAD_URL}" | tar -xz --strip-components=5 -C /home/user/tools/ "${REPO}-${BRANCH}/${TOOLS_DIR}"
6464

65-
# Conditional wait for remote service based on llm_engine
66-
if [ "$llm_engine" = "tgi" ]; then
67-
until nc -z -v -w30 ${llm_endpoint_url#http://} 80; do
68-
echo "Waiting for remote service...";
69-
sleep 5;
70-
done
71-
fi
72-
envFrom:
73-
- configMapRef:
74-
name: config-{endpoint}
75-
# volumeMounts:
76-
# - name: agent-tools
77-
# mountPath: /home/user/tools/
78-
securityContext:
79-
runAsUser: 0
80-
runAsGroup: 0
65+
# # Conditional wait for remote service based on llm_engine
66+
# if [ "$llm_engine" = "tgi" ]; then
67+
# until nc -z -v -w30 ${llm_endpoint_url#http://} 80; do
68+
# echo "Waiting for remote service...";
69+
# sleep 5;
70+
# done
71+
# fi
72+
# envFrom:
73+
# - configMapRef:
74+
# name: config-{endpoint}
75+
# volumeMounts:
76+
# - name: agent-tools
77+
# mountPath: /home/user/tools/
78+
# securityContext:
79+
# runAsUser: 0
80+
# runAsGroup: 0
8181
containers:
8282
- name: sql-agent-container
8383
image: ${REGISTRY}/agent:${TAG}
@@ -93,8 +93,8 @@ spec:
9393
ports:
9494
- containerPort: 9096
9595
# volumeMounts:
96-
# - name: agent-tools
97-
# mountPath: /home/user/tools/
96+
# - name: agent-tools
97+
# mountPath: /home/user/tools/
9898
envFrom:
9999
- configMapRef:
100100
name: config-{endpoint}

0 commit comments

Comments
 (0)