Skip to content

Commit 163bb32

Browse files
committed
Modified CI with specific NS
1 parent 16ddf91 commit 163bb32

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

.github/workflows/deploy-and-test.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,27 @@ jobs:
2323
- name: Create Kubernetes cluster
2424
run: kind create cluster --name test-cluster
2525

26+
- name: Create Namespace
27+
run: kubectl create namespace xcermak5
28+
2629
- name: Helm Install
27-
run: helm install mychart ./manifests/mychart
30+
run: helm install mychart ./manifests/mychart --namespace xcermak5
2831

2932
- name: Wait for Kubernetes resources to be ready
3033
run: |
31-
kubectl wait --for=condition=available --timeout=600s deployment --all
32-
kubectl get all
34+
kubectl wait --for=condition=available --timeout=600s deployment --namespace xcermak5 --all
35+
kubectl get all --namespace xcermak5
3336
3437
- name: Run Integration Tests
3538
run: |
3639
# Example integration test commands
3740
# Replace these with your actual integration test commands
38-
kubectl get pods
39-
kubectl get services
41+
kubectl get pods --namespace xcermak5
42+
kubectl get services --namespace xcermak5
4043
# You can add curl or other commands to test the endpoints
4144
# For example:
42-
# POD_NAME=$(kubectl get pods -l app=mychart -o jsonpath="{.items[0].metadata.name}")
43-
# kubectl exec $POD_NAME -- curl -f http://localhost:8080/healthz
45+
# POD_NAME=$(kubectl get pods --namespace xcermak5 -l app=mychart -o jsonpath="{.items[0].metadata.name}")
46+
# kubectl exec --namespace xcermak5 $POD_NAME -- curl -f http://localhost:8080/healthz
4447
4548
- name: Delete Kubernetes cluster
4649
run: kind delete cluster --name test-cluster

0 commit comments

Comments
 (0)