Skip to content

Commit 1ee5773

Browse files
committed
refactor(manifests): use full deployment and service account names
Signed-off-by: alokdangre <alokdangre@gmail.com>
1 parent e671bbe commit 1ee5773

File tree

6 files changed

+19
-15
lines changed

6 files changed

+19
-15
lines changed

.github/workflows/test-manifests.yaml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ permissions:
1010
actions: read
1111

1212
jobs:
13-
test-models-web-app:
13+
test-models-web-application:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout Models Web Application
@@ -50,6 +50,10 @@ jobs:
5050
cp -R models-web-app/manifests/kustomize/components manifests/applications/kserve/models-web-app/
5151
cp -R models-web-app/manifests/kustomize/overlays manifests/applications/kserve/models-web-app/
5252
53+
- name: Align kubeflow/manifests KServe install test with renamed deployment
54+
run: |
55+
sed -i 's#deployment/kserve-models-web-app#deployment/kserve-models-web-application#g' manifests/tests/kserve_install.sh
56+
5357
- name: Install Istio CNI
5458
working-directory: manifests
5559
run: ./tests/istio-cni_install.sh
@@ -90,7 +94,7 @@ jobs:
9094
- name: Wait for KServe Models Web Application deployment
9195
run: |
9296
kubectl wait --for=condition=Ready pods --all --all-namespaces --timeout=300s --field-selector=status.phase!=Succeeded
93-
kubectl wait --for=condition=Available deployment/kserve-models-web-app -n kubeflow --timeout=60s
97+
kubectl wait --for=condition=Available deployment/kserve-models-web-application -n kubeflow --timeout=60s
9498
sleep 10
9599
96100
- name: Setup python 3.12
@@ -109,8 +113,8 @@ jobs:
109113
if: failure()
110114
run: |
111115
kubectl get deployment,service,endpoints,pods -n kubeflow -l app.kubernetes.io/component=kserve-models-web-app || true
112-
kubectl describe deployment kserve-models-web-app -n kubeflow || true
113-
kubectl logs deployment/kserve-models-web-app -n kubeflow --all-containers=true --tail=200 || true
116+
kubectl describe deployment kserve-models-web-application -n kubeflow || true
117+
kubectl logs deployment/kserve-models-web-application -n kubeflow --all-containers=true --tail=200 || true
114118
115119
- name: Apply Pod Security Standards restricted levels
116120
working-directory: manifests

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,12 +95,12 @@ Add the environment variable to your deployment configuration:
9595
apiVersion: apps/v1
9696
kind: Deployment
9797
metadata:
98-
name: kserve-models-web-app
98+
name: kserve-models-web-application
9999
spec:
100100
template:
101101
spec:
102102
containers:
103-
- name: kserve-models-web-app
103+
- name: kserve-models-web-application
104104
env:
105105
- name: ALLOWED_NAMESPACES
106106
value: "kubeflow-user,kubeflow-admin"

manifests/kustomize/base/deployment.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: apps/v1
22
kind: Deployment
33
metadata:
4-
name: kserve-models-web-app
4+
name: kserve-models-web-application
55
namespace: kserve
66
spec:
77
replicas: 1
@@ -54,4 +54,4 @@ spec:
5454
drop:
5555
- ALL
5656
runAsUser: 1000
57-
serviceAccountName: kserve-models-web-app
57+
serviceAccountName: kserve-models-web-application

manifests/kustomize/base/rbac.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
apiVersion: v1
22
kind: ServiceAccount
33
metadata:
4-
name: kserve-models-web-app
4+
name: kserve-models-web-application
55
namespace: kserve
66
---
77
apiVersion: rbac.authorization.k8s.io/v1
88
kind: ClusterRole
99
metadata:
10-
name: kserve-models-web-app-cluster-role
10+
name: kserve-models-web-application-cluster-role
1111
rules:
1212
- apiGroups:
1313
- authorization.k8s.io
@@ -57,12 +57,12 @@ rules:
5757
apiVersion: rbac.authorization.k8s.io/v1
5858
kind: ClusterRoleBinding
5959
metadata:
60-
name: kserve-models-web-app-binding
60+
name: kserve-models-web-application-binding
6161
roleRef:
6262
apiGroup: rbac.authorization.k8s.io
6363
kind: ClusterRole
64-
name: kserve-models-web-app-cluster-role
64+
name: kserve-models-web-application-cluster-role
6565
subjects:
6666
- kind: ServiceAccount
67-
name: kserve-models-web-app
67+
name: kserve-models-web-application
6868
namespace: kserve

manifests/kustomize/components/istio/web-app-sidecar.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: apps/v1
22
kind: Deployment
33
metadata:
4-
name: kserve-models-web-app
4+
name: kserve-models-web-application
55
namespace: kserve
66
spec:
77
template:

manifests/tests/kserve_test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ fi
110110
# ============================================================
111111
# Test 3: KServe Models Web Application API
112112
# ============================================================
113-
kubectl wait --for=condition=Available --timeout=300s -n kubeflow deployment/kserve-models-web-app
113+
kubectl wait --for=condition=Available --timeout=300s -n kubeflow deployment/kserve-models-web-application
114114

115115
TOKEN="$(kubectl -n ${NAMESPACE} create token default-editor)"
116116
BASE_URL="localhost:8080/kserve-endpoints"

0 commit comments

Comments
 (0)