From edda214c1dcd09d6903916a91084e9931dd2f469 Mon Sep 17 00:00:00 2001 From: gabriel-farache Date: Tue, 5 Nov 2024 14:40:09 +0100 Subject: [PATCH] FFFFiiixxx Signed-off-by: gabriel-farache --- .github/workflows/create-ocp-project.yaml | 2 +- .github/workflows/greeting.yaml | 2 +- .github/workflows/modify-vm-resources.yaml | 4 ++-- .github/workflows/mtv-migration.yaml | 4 ++-- .github/workflows/mtv-plan.yaml | 4 ++-- .github/workflows/request-vm-cnv.yaml | 4 ++-- e2e/move2kube.sh | 2 +- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/create-ocp-project.yaml b/.github/workflows/create-ocp-project.yaml index 58536782..c53010c0 100644 --- a/.github/workflows/create-ocp-project.yaml +++ b/.github/workflows/create-ocp-project.yaml @@ -108,8 +108,8 @@ jobs: run: | kubectl expose "$(kubectl get pod -o name | grep create-ocp-project)" --type="NodePort" --port=8080 --name=create-ocp-project-svc kubectl port-forward svc/create-ocp-project-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/create-ocp-project' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/create-ocp-project' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/.github/workflows/greeting.yaml b/.github/workflows/greeting.yaml index b18812b1..099aff9c 100644 --- a/.github/workflows/greeting.yaml +++ b/.github/workflows/greeting.yaml @@ -67,8 +67,8 @@ jobs: run: | kubectl expose "$(kubectl get pod -o name | grep greeting)" --type="NodePort" --port=8080 --name=greeting-svc kubectl port-forward svc/greeting-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/greeting' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/greeting' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/.github/workflows/modify-vm-resources.yaml b/.github/workflows/modify-vm-resources.yaml index 08d45179..227b9f4e 100644 --- a/.github/workflows/modify-vm-resources.yaml +++ b/.github/workflows/modify-vm-resources.yaml @@ -102,14 +102,14 @@ jobs: ' kubectl scale deploy "${WORKFLOW_NAME}" --replicas=0 kubectl get pod -A - kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m + kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m || kubectl describe pod -l app="${WORKFLOW_NAME}" - name: Test workflow is responsive run: | kubectl expose "$(kubectl get pod -o name | grep modify-vm-resources)" --type="NodePort" --port=8080 --name=modify-vm-resources-svc kubectl port-forward svc/modify-vm-resources-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/modify-vm-resources' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/modify-vm-resources' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/.github/workflows/mtv-migration.yaml b/.github/workflows/mtv-migration.yaml index 3e12beaf..b8438805 100644 --- a/.github/workflows/mtv-migration.yaml +++ b/.github/workflows/mtv-migration.yaml @@ -89,14 +89,14 @@ jobs: ' kubectl scale deploy "${WORKFLOW_NAME}" --replicas=0 kubectl get pod -A - kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m + kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m || kubectl describe pod -l app="${WORKFLOW_NAME}" - name: Test workflow is responsive run: | kubectl expose "$(kubectl get pod -o name | grep mtv-migration)" --type="NodePort" --port=8080 --name=mtv-migration-svc kubectl port-forward svc/mtv-migration-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/mtv-migration' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/mtv-migration' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/.github/workflows/mtv-plan.yaml b/.github/workflows/mtv-plan.yaml index c4620814..a5eb7d77 100644 --- a/.github/workflows/mtv-plan.yaml +++ b/.github/workflows/mtv-plan.yaml @@ -89,14 +89,14 @@ jobs: ' kubectl scale deploy "${WORKFLOW_NAME}" --replicas=0 kubectl get pod -A - kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m + kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m || kubectl describe pod -l app="${WORKFLOW_NAME}" - name: Test workflow is responsive run: | kubectl expose "$(kubectl get pod -o name | grep mtv-plan)" --type="NodePort" --port=8080 --name=mtv-plan-svc kubectl port-forward svc/mtv-plan-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/mtv-plan' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/mtv-plan' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/.github/workflows/request-vm-cnv.yaml b/.github/workflows/request-vm-cnv.yaml index cfd89068..211947a0 100644 --- a/.github/workflows/request-vm-cnv.yaml +++ b/.github/workflows/request-vm-cnv.yaml @@ -102,14 +102,14 @@ jobs: ' kubectl scale deploy "${WORKFLOW_NAME}" --replicas=0 kubectl get pod -A - kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m + kubectl wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m || kubectl describe pod -l app="${WORKFLOW_NAME}" - name: Test workflow is responsive run: | kubectl expose "$(kubectl get pod -o name | grep request-vm-cnv)" --type="NodePort" --port=8080 --name=request-vm-cnv-svc kubectl port-forward svc/request-vm-cnv-svc 8080:8080 & - status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/request-vm-cnv' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') sleep 3 + status_code=$(curl s -o /dev/null -w '%{http_code}' -XGET --location 'http://localhost:8080/request-vm-cnv' --header 'Accept: application/json, text/plain, */*' --header 'Content-Type: application/json') if [ "$status_code" -ne 200 ]; then echo "$status_code" exit 1 diff --git a/e2e/move2kube.sh b/e2e/move2kube.sh index 99ced3da..5f1c46b0 100755 --- a/e2e/move2kube.sh +++ b/e2e/move2kube.sh @@ -27,7 +27,7 @@ sleep 3 echo "Proxy Janus-idp port ✅" echo "Proxy move2kube instance port ⏳" -kubectl -n "${M2K_INSTANCE_NS}" port-forward svc/move2kube-instance-svc 8080:8080 & +kubectl -n "${M2K_INSTANCE_NS}" port-forward svc/move2kube-svc 8080:8080 & move2kube_port_forward_pid="$!" sleep 3 echo "Proxy move2kube instance port ✅"