Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -74,24 +74,26 @@ for OLS_TEST_DURATION in "${test_durations[@]}"; do
run_or_fail make deploy
run_or_fail oc adm policy add-cluster-role-to-user cluster-admin system:serviceaccount:openshift-lightspeed:lightspeed-operator-controller-manager
run_or_fail oc patch deployment lightspeed-operator-controller-manager \
-n openshift-lightspeed \
--type='json' \
-p='[
{
"op": "add",
"path": "/spec/template/spec/containers/0/securityContext",
"value": {
"allowPrivilegeEscalation": false,
"seccompProfile": {
"type": "RuntimeDefault"
},
"capabilities": {
"drop": ["ALL"]
-n openshift-lightspeed \
--type='json' \
-p='[
{
"op": "add",
"path": "/spec/template/spec/containers/0/securityContext",
"value": {
"allowPrivilegeEscalation": false,
"readOnlyRootFilesystem": true,
"runAsNonRoot": true,
"seccompProfile": {
"type": "RuntimeDefault"
},
"capabilities": {
"drop": ["ALL"]
}
}
}
}
]'
run_or_fail oc wait --for=condition=Available -n openshift-lightspeed deployment lightspeed-operator-controller-manager --timeout=600s
]' || true
run_or_fail oc wait --for=condition=Available -n openshift-lightspeed deployment lightspeed-operator-controller-manager --timeout=900s
popd

# Deploy olsconfig with fake values
Expand Down Expand Up @@ -295,17 +297,32 @@ EOF

# Clean up
run_or_fail oc delete namespace ols-load-test
run_or_fail oc wait --for=delete ns/ols-load-test --timeout=600s
oc wait --for=delete ns/ols-load-test --timeout=600s || true
run_or_fail oc logs -n openshift-lightspeed deployment/lightspeed-app-server --since-time="$LOG_START_TIME" > ols_${OLS_TEST_WORKERS}_${OLS_TEST_DURATION}.txt
run_or_fail cp ols_${OLS_TEST_WORKERS}_${OLS_TEST_DURATION}.txt ${ARTIFACT_DIR}/ols_${OLS_TEST_WORKERS}_${OLS_TEST_DURATION}.txt

pushd lightspeed-operator
run_or_fail make undeploy
timeout 120s make undeploy || true
timeout 60s kubectl api-resources --verbs=list --namespaced -o name \
| xargs -n 1 kubectl get -n openshift-lightspeed -o json --ignore-not-found \
| jq -r '.items[] | select(.metadata.deletionTimestamp != null) | .apiVersion + " " + .kind + " " + .metadata.name' \
| while read kind name; do
kubectl patch -n openshift-lightspeed "$kind/$name" \
-p '{"metadata":{"finalizers":[]}}' --type=merge || true
done || true
timeout 60s kubectl api-resources --verbs=list --namespaced=false -o name \
| xargs -n 1 kubectl get -o json --ignore-not-found \
| jq -r '.items[] | select(.metadata.deletionTimestamp != null) | .kind + " " + .metadata.name' \
| while read kind name; do
kubectl patch "$kind/$name" \
-p '{"metadata":{"finalizers":[]}}' --type=merge || true
done || true

popd
job_end=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
log_fingerprint

sleep 300
sleep 180
done

popd