Files
odo/.ibm/pipelines/openshift-tests.sh
Philippe Martin f4a860ec2e Install and use a reverse proxy for staging devfile registry (#5922)
* Kubernetes Manifests to deploy nginx reverse proxy for staging devfile registry

* Get the external address of the loadBalancer service for devfile proxy

* If DEVFILE_PROXY is defined, use it as Devfile registry

* Fix get address from Windows

* Add some log displaying proxy address found

* Filter requests on user agent

* Add Go-http-client user-agent

* Add doc
2022-07-20 11:31:25 +02:00

28 lines
685 B
Bash
Executable File

#!/bin/bash
LOGFILE="pr-${GIT_PR_NUMBER}-openshift-tests-${BUILD_NUMBER}"
source .ibm/pipelines/functions.sh
ibmcloud login --apikey "${API_KEY_QE}"
ibmcloud target -r eu-de
ibmcloud oc cluster config -c "${CLUSTER_ID}"
oc login -u apikey -p "${API_KEY_QE}" "${IBM_OPENSHIFT_ENDPOINT}"
cleanup_namespaces
(
set -e
export DEVFILE_PROXY="$(kubectl get svc -n devfile-proxy nginx -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' || true)"
echo Using Devfile proxy: ${DEVFILE_PROXY}
make install
make test-integration
make test-e2e
) |& tee "/tmp/${LOGFILE}"
RESULT=${PIPESTATUS[0]}
save_logs "${LOGFILE}" "OpenShift Tests" ${RESULT}
exit ${RESULT}