diff --git a/.github/workflows/create-ocp-project.yaml b/.github/workflows/create-ocp-project.yaml index 168da942..58536782 100644 --- a/.github/workflows/create-ocp-project.yaml +++ b/.github/workflows/create-ocp-project.yaml @@ -102,7 +102,7 @@ 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: | diff --git a/.github/workflows/greeting.yaml b/.github/workflows/greeting.yaml index 064f7f2e..b18812b1 100644 --- a/.github/workflows/greeting.yaml +++ b/.github/workflows/greeting.yaml @@ -61,7 +61,7 @@ jobs: helm install greeting greeting WORKFLOW_NAME=greeting 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: | diff --git a/.github/workflows/mta-v7.x-e2e.yaml b/.github/workflows/mta-v7.x-e2e.yaml index d763058d..2b9e315d 100644 --- a/.github/workflows/mta-v7.x-e2e.yaml +++ b/.github/workflows/mta-v7.x-e2e.yaml @@ -94,6 +94,7 @@ jobs: )" charts/mta-v7.x/templates/0?-sonataflow_mta-analysis-v7.yaml # we are on k8s, not OCP, some resources are not available rm -rf charts/mta-v7.x/templates/00-mta-operator.yaml + rm -rf charts/mta-v7.x/templates/00-tackle-resources.yaml K8S_INSTALL=1 MTA_HELM_REPO=charts/mta-v7.x/ TARGET_NS=default ./docs/main/mta-v7.x/install-mta-v7.sh - uses: actions/checkout@v4 diff --git a/docs/main/mta-v7.x/install-mta-v7.sh b/docs/main/mta-v7.x/install-mta-v7.sh index 9bad2dd2..925c6984 100755 --- a/docs/main/mta-v7.x/install-mta-v7.sh +++ b/docs/main/mta-v7.x/install-mta-v7.sh @@ -18,16 +18,19 @@ fi helm install mta ${MTA_HELM_REPO} -n ${TARGET_NS} WORKFLOW_NAME=mta-analysis-v7 -"${CLUSTER_CLIENT}" -n ${TARGET_NS} patch secret "${WORKFLOW_NAME}-creds" --type merge -p '{"data": { "NOTIFICATIONS_BEARER_TOKEN": "'$("${CLUSTER_CLIENT}" get secrets -n rhdh-operator backstage-backend-auth-secret -o go-template='{{ .data.BACKEND_SECRET }}')'"}}' if [[ -z "${K8S_INSTALL}" ]]; then + "${CLUSTER_CLIENT}" -n ${TARGET_NS} patch secret "${WORKFLOW_NAME}-creds" --type merge -p '{"data": { "NOTIFICATIONS_BEARER_TOKEN": "'$("${CLUSTER_CLIENT}" get secrets -n rhdh-operator backstage-backend-auth-secret -o go-template='{{ .data.BACKEND_SECRET }}')'"}}' + BACKSTAGE_NOTIFICATIONS_URL=http://backstage-backstage.rhdh-operator + while [[ $retry_count -lt 5 ]]; do "${CLUSTER_CLIENT}" -n openshift-mta get route mta && break || sleep 60 retry_count=$((retry_count + 1)) done MTA_ROUTE="https://"$("${CLUSTER_CLIENT}" -n openshift-mta get route mta -o yaml | yq -r .spec.host) else + "${CLUSTER_CLIENT}" -n ${TARGET_NS} patch secret "${WORKFLOW_NAME}-creds" --type merge -p '{"data": { "NOTIFICATIONS_BEARER_TOKEN": "'$("${CLUSTER_CLIENT}" get secret orchestrator-auth -o jsonpath={.data.backend-secret})'"}}' + BACKSTAGE_NOTIFICATIONS_URL=http://orchestrator-backstage.default.svc.cluster.local:7007 MTA_ROUTE="http://tackle-ui.my-konveyor-operator.svc.cluster.local:8080" fi -BACKSTAGE_NOTIFICATIONS_URL=http://backstage-backstage.rhdh-operator "${CLUSTER_CLIENT}" -n "${TARGET_NS}" patch sonataflow mta-analysis-v7 --type merge -p '{"spec": { "podTemplate": { "container": { "env": [{"name": "BACKSTAGE_NOTIFICATIONS_URL", "value": "'${BACKSTAGE_NOTIFICATIONS_URL}'"}, {"name": "MTA_URL", "value": "'${MTA_ROUTE}'"}]}}}}' "${CLUSTER_CLIENT}" -n "${TARGET_NS}" wait --for=condition=Ready=true pods -l app="${WORKFLOW_NAME}" --timeout=1m \ No newline at end of file diff --git a/e2e/move2kube.sh b/e2e/move2kube.sh index f60c6d6c..99ced3da 100755 --- a/e2e/move2kube.sh +++ b/e2e/move2kube.sh @@ -5,7 +5,7 @@ set -e # holds the pid of the port forward process for cleanups export port_forward_pid="" -export M2K_INSTANCE_NS=move2kube +export M2K_INSTANCE_NS="move2kube" function cleanup() { echo "cleanup $?" @@ -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-instance-svc 8080:8080 & move2kube_port_forward_pid="$!" sleep 3 echo "Proxy move2kube instance port ✅"