diff --git a/ci-scripts/scripts/oc-deploy-physims.sh b/ci-scripts/scripts/oc-deploy-physims.sh index c0b4e388c1..29812a8980 100755 --- a/ci-scripts/scripts/oc-deploy-physims.sh +++ b/ci-scripts/scripts/oc-deploy-physims.sh @@ -9,9 +9,11 @@ IMG_TAG=${3} OAI_DIR=${4} cat /opt/oc-password | oc login -u oaicicd --server https://api.oai.cs.eurecom.fr:6443 > /dev/null +set -x oc project ${OC_NS} > /dev/null oc tag oaicicd-ran/oai-physim:${IMG_TAG} ${OC_NS}/oai-physim:${IMG_TAG} helm install ${OC_RELEASE} ${OAI_DIR}/charts/${OC_RELEASE} --set global.image.version=${IMG_TAG} --wait --timeout 120s +set +x POD_ID=$(oc get pods | grep oai-${OC_RELEASE} | awk '{print $1}') wait_creating=30 while [[ $(oc describe pod "$POD_ID" | grep "ContainerCreating") && ${wait_creating} > 0 ]]; do @@ -29,6 +31,7 @@ oc logs -f -n ${OC_NS} "$POD_ID" | while read -r line; do break fi done +set -x oc logs -n ${OC_NS} "$POD_ID" >> ${OAI_DIR}/physim_log.txt oc describe pod $POD_ID >> ${OAI_DIR}/physim_log.txt helm uninstall ${OC_RELEASE} --wait