Skip to content

Commit 758d236

Browse files
Add chatQnA UI manifest (opea-project#669)
* Add chatQnA UI manifest Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update port Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * add nginx config Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * update code * update nginx config Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update nginx config Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update ui IP Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update yaml Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update api Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update env config Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update env Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * update specify node Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * update node-type Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update yaml Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * update yaml Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * delete nodeSelector Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * update dataprep api Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * add node-type Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * delete specify nodeSelector Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> * delete useless space Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> --------- Signed-off-by: Yue, Wenjiao <wenjiao.yue@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent ac34860 commit 758d236

File tree

1 file changed

+191
-0
lines changed

1 file changed

+191
-0
lines changed

ChatQnA/kubernetes/manifests/xeon/chatqna.yaml

Lines changed: 191 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,72 @@
33
# Copyright (C) 2024 Intel Corporation
44
# SPDX-License-Identifier: Apache-2.0
55

6+
apiVersion: v1
7+
kind: ConfigMap
8+
metadata:
9+
name: chatqna-nginx-config
10+
labels:
11+
helm.sh/chart: chatqna-nginx-0.8.0
12+
app.kubernetes.io/name: chatqna-nginx
13+
app.kubernetes.io/instance: chatqna-nginx
14+
app.kubernetes.io/version: "v0.8"
15+
app.kubernetes.io/managed-by: Helm
16+
data:
17+
default.conf: |
18+
server {
19+
listen 80;
20+
listen [::]:80;
21+
22+
location /home {
23+
root /usr/share/nginx/html;
24+
index index.html index.htm;
25+
}
26+
27+
location / {
28+
proxy_pass http://chatqna-ui.default.svc.cluster.local:5173;
29+
proxy_set_header Host $host;
30+
proxy_set_header X-Real-IP $remote_addr;
31+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
32+
proxy_set_header X-Forwarded-Proto $scheme;
33+
}
34+
35+
location /v1/chatqna {
36+
proxy_pass http://chatqna.default.svc.cluster.local:8888;
37+
proxy_set_header Host $host;
38+
proxy_set_header X-Real-IP $remote_addr;
39+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
40+
proxy_set_header X-Forwarded-Proto $scheme;
41+
}
42+
43+
location /v1/dataprep {
44+
proxy_pass http://chatqna-data-prep.default.svc.cluster.local:6007;
45+
proxy_set_header Host $host;
46+
proxy_set_header X-Real-IP $remote_addr;
47+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
48+
proxy_set_header X-Forwarded-Proto $scheme;
49+
}
50+
51+
location /v1/dataprep/get_file {
52+
proxy_pass http://chatqna-data-prep.default.svc.cluster.local:6007;
53+
proxy_set_header Host $host;
54+
proxy_set_header X-Real-IP $remote_addr;
55+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
56+
proxy_set_header X-Forwarded-Proto $scheme;
57+
}
58+
59+
location /v1/dataprep/delete_file {
60+
proxy_pass http://chatqna-data-prep.default.svc.cluster.local:6007;
61+
proxy_set_header Host $host;
62+
proxy_set_header X-Real-IP $remote_addr;
63+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
64+
proxy_set_header X-Forwarded-Proto $scheme;
65+
}
66+
}
67+
---
68+
# Source: chatqna/charts/data-prep/templates/configmap.yaml
69+
# Copyright (C) 2024 Intel Corporation
70+
# SPDX-License-Identifier: Apache-2.0
71+
672
apiVersion: v1
773
kind: ConfigMap
874
metadata:
@@ -457,6 +523,31 @@ spec:
457523
app.kubernetes.io/name: chatqna
458524
app.kubernetes.io/instance: chatqna
459525
---
526+
# Source: chatqna/templates/service.yaml
527+
# Copyright (C) 2024 Intel Corporation
528+
# SPDX-License-Identifier: Apache-2.0
529+
530+
apiVersion: v1
531+
kind: Service
532+
metadata:
533+
name: chatqna-ui
534+
labels:
535+
helm.sh/chart: chatqna-ui-0.8.0
536+
app.kubernetes.io/name: chatqna-ui
537+
app.kubernetes.io/instance: chatqna-ui
538+
app.kubernetes.io/version: "v0.8"
539+
app.kubernetes.io/managed-by: Helm
540+
spec:
541+
type: ClusterIP
542+
ports:
543+
- port: 5173
544+
targetPort: 5173
545+
protocol: TCP
546+
name: chatqna-ui
547+
selector:
548+
app.kubernetes.io/name: chatqna-ui
549+
app.kubernetes.io/instance: chatqna-ui
550+
---
460551
# Source: chatqna/charts/data-prep/templates/deployment.yaml
461552
# Copyright (C) 2024 Intel Corporation
462553
# SPDX-License-Identifier: Apache-2.0
@@ -923,6 +1014,49 @@ spec:
9231014
# Copyright (C) 2024 Intel Corporation
9241015
# SPDX-License-Identifier: Apache-2.0
9251016

1017+
apiVersion: apps/v1
1018+
kind: Deployment
1019+
metadata:
1020+
name: chatqna-ui
1021+
labels:
1022+
helm.sh/chart: chatqna-ui-0.8.0
1023+
app.kubernetes.io/name: chatqna-ui
1024+
app.kubernetes.io/instance: chatqna-ui
1025+
app.kubernetes.io/version: "v0.8"
1026+
app.kubernetes.io/managed-by: Helm
1027+
spec:
1028+
replicas: 1
1029+
selector:
1030+
matchLabels:
1031+
app.kubernetes.io/name: chatqna-ui
1032+
app.kubernetes.io/instance: chatqna-ui
1033+
template:
1034+
metadata:
1035+
annotations:
1036+
sidecar.istio.io/rewriteAppHTTPProbers: 'true'
1037+
labels:
1038+
app.kubernetes.io/name: chatqna-ui
1039+
app.kubernetes.io/instance: chatqna-ui
1040+
spec:
1041+
securityContext:
1042+
{}
1043+
hostIPC: true
1044+
containers:
1045+
- name: chatqna-ui
1046+
securityContext:
1047+
{}
1048+
image: "opea/chatqna-ui:latest"
1049+
imagePullPolicy: IfNotPresent
1050+
args: null
1051+
ports:
1052+
- name: http
1053+
containerPort: 5173
1054+
protocol: TCP
1055+
---
1056+
# Source: chatqna/charts/tei/templates/deployment.yaml
1057+
# Copyright (C) 2024 Intel Corporation
1058+
# SPDX-License-Identifier: Apache-2.0
1059+
9261060
apiVersion: apps/v1
9271061
kind: Deployment
9281062
metadata:
@@ -1239,3 +1373,60 @@ spec:
12391373
volumes:
12401374
- name: tmp
12411375
emptyDir: {}
1376+
---
1377+
# Copyright (C) 2024 Intel Corporation
1378+
# SPDX-License-Identifier: Apache-2.0
1379+
1380+
apiVersion: apps/v1
1381+
kind: Deployment
1382+
metadata:
1383+
name: chatqna-nginx-deployment
1384+
labels:
1385+
helm.sh/chart: chatqna-nginx-0.8.0
1386+
app.kubernetes.io/name: chatqna-nginx
1387+
app.kubernetes.io/instance: chatqna-nginx
1388+
app.kubernetes.io/version: "v0.8"
1389+
app.kubernetes.io/managed-by: Helm
1390+
spec:
1391+
replicas: 1
1392+
selector:
1393+
matchLabels:
1394+
app: chatqna-nginx
1395+
template:
1396+
metadata:
1397+
labels:
1398+
app: chatqna-nginx
1399+
spec:
1400+
containers:
1401+
- name: chatqna-nginx
1402+
image: nginx:latest
1403+
ports:
1404+
- containerPort: 80
1405+
volumeMounts:
1406+
- name: nginx-config-volume
1407+
mountPath: /etc/nginx/conf.d/default.conf
1408+
subPath: default.conf
1409+
volumes:
1410+
- name: nginx-config-volume
1411+
configMap:
1412+
name: chatqna-nginx-config
1413+
---
1414+
kind: Service
1415+
apiVersion: v1
1416+
metadata:
1417+
name: chatqna-nginx-svc
1418+
labels:
1419+
helm.sh/chart: chatqna-nginx-0.8.0
1420+
app.kubernetes.io/name: chatqna-nginx
1421+
app.kubernetes.io/instance: chatqna-nginx
1422+
app.kubernetes.io/version: "v0.8"
1423+
app.kubernetes.io/managed-by: Helm
1424+
spec:
1425+
selector:
1426+
app: chatqna-nginx
1427+
ports:
1428+
- protocol: TCP
1429+
port: 80
1430+
targetPort: 80
1431+
nodePort: 30789
1432+
type: NodePort

0 commit comments

Comments
 (0)