Skip to content

Commit 2f8ceed

Browse files
committed
Resolving failure for PYPY 3.10
1 parent 5b7c0ab commit 2f8ceed

File tree

1 file changed

+7
-25
lines changed

1 file changed

+7
-25
lines changed

.github/workflows/ci.yaml

Lines changed: 7 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ jobs:
4848
helm repo add vertica-charts https://vertica.github.io/charts || true
4949
helm repo add bitnami https://charts.bitnami.com/bitnami || true
5050
helm repo update
51-
5251
# ---------------------------
5352
# MinIO Setup
5453
# ---------------------------
@@ -105,7 +104,6 @@ jobs:
105104
kubectl -n minio rollout status deployment/minio --timeout=2m || true
106105
kubectl get pods -n minio -o wide || true
107106
kubectl get svc -n minio || true
108-
109107
- name: Ensure MinIO bucket exists
110108
run: |
111109
kubectl run mc-client --rm -i --restart=Never \
@@ -116,7 +114,6 @@ jobs:
116114
mc mb --ignore-existing localminio/vertica-fleeting && \
117115
mc ls localminio
118116
"
119-
120117
- name: Create MinIO Secret
121118
run: |
122119
kubectl create ns my-verticadb-operator || true
@@ -126,7 +123,6 @@ jobs:
126123
--from-literal=accesskey="minioadmin" \
127124
--from-literal=secretkey="minioadmin"
128125
kubectl get secret communal-creds -n my-verticadb-operator -o yaml || true
129-
130126
# ---------------------------
131127
# Vertica Operator + DB Deployment
132128
# ---------------------------
@@ -209,7 +205,6 @@ jobs:
209205
- port: 5433
210206
targetPort: 5433
211207
EOF
212-
213208
- name: Wait for Vertica readiness
214209
run: |
215210
NS=my-verticadb-operator
@@ -219,22 +214,22 @@ jobs:
219214
kubectl get pod ${POD} -n ${NS} && break || sleep 10
220215
done
221216
kubectl wait --for=condition=Ready pod/${POD} -n ${NS} --timeout=5m || true
222-
223217
echo "🚀 Creating test runner pod..."
224-
kubectl -n ${NS} run test-runner --image=python:3.13-slim --restart=Never --command -- sleep infinity
218+
if [[ "${IMAGE}" == *"pypy"* ]]; then
219+
- START_CMD="python -c 'import time; time.sleep(10**6)'"
220+
- else
221+
- START_CMD="sleep infinity"
222+
- fi
223+
- kubectl -n ${NS} run ${POD} --image=${IMAGE} --restart=Never --command -- ${START_CMD}
225224
kubectl -n ${NS} wait --for=condition=Ready pod/test-runner --timeout=180s
226-
227225
echo "🩹 Adding Vertica pod entries to /etc/hosts in test pod..."
228226
for p in $(kubectl -n $NS get pods -l app.kubernetes.io/instance=verticadb-sample -o jsonpath='{.items[*].metadata.name}'); do
229227
IP=$(kubectl -n $NS get pod $p -o jsonpath='{.status.podIP}')
230228
echo "$IP $p.$NS.svc.cluster.local $p" | kubectl -n $NS exec -i test-runner -- tee -a /etc/hosts >/dev/null
231229
echo "✔ Added $p -> $IP"
232230
done
233-
234231
echo "📂 Copying repository into pod..."
235232
kubectl -n ${NS} cp . test-runner:/workspace
236-
237-
238233
# ---------------------------
239234
# Keycloak + OAuth setup
240235
# ---------------------------
@@ -288,12 +283,10 @@ jobs:
288283
- port: 8080
289284
targetPort: 8080
290285
EOF
291-
292286
- name: Wait for Keycloak readiness
293287
run: |
294288
kubectl -n keycloak rollout status deploy/keycloak --timeout=2m
295289
kubectl -n keycloak get pods -o wide
296-
297290
- name: Configure Keycloak realm, client, and user
298291
run: |
299292
kubectl -n keycloak exec deploy/keycloak -- \
@@ -314,7 +307,6 @@ jobs:
314307
kubectl -n keycloak exec deploy/keycloak -- \
315308
/opt/keycloak/bin/kcadm.sh set-password -r test \
316309
--username oauth_user --new-password password
317-
318310
- name: Configure Vertica Authentication
319311
run: |
320312
NS=my-verticadb-operator
@@ -342,15 +334,14 @@ jobs:
342334
run: |
343335
kubectl -n my-verticadb-operator exec verticadb-sample-defaultsubcluster-0 -c server -- \
344336
/opt/vertica/bin/vsql -U dbadmin -c "SELECT get_load_balance_policy();"
345-
346337
- name: Run Python tests in-cluster
347338
run: |
348339
set -euo pipefail
349340
NS=my-verticadb-operator
350341
SVC=verticadb-sample-defaultsubcluster
351342
LOCATOR="${SVC}.${NS}.svc.cluster.local:5433"
352343
POD=py-test-runner
353-
IMAGE=python:${{ matrix.python-version }}-slim
344+
IMAGE=python:${{ matrix.python-version }}
354345
echo "Ensuring namespace ${NS} exists..."
355346
kubectl get ns ${NS} >/dev/null 2>&1 || kubectl create ns ${NS}
356347
echo "Waiting for Vertica service endpoints..."
@@ -437,41 +428,32 @@ jobs:
437428
"
438429
echo "Cleaning up test pod..."
439430
kubectl -n ${NS} delete pod ${POD} --ignore-not-found || true
440-
441431
# ---------------------------
442432
# Final Teardown (K8s + KinD)
443433
# ---------------------------
444434
- name: Cleanup Kubernetes resources
445435
if: always()
446436
run: |
447437
echo "Starting cleanup..."
448-
449438
echo "Deleting Python test runner pods..."
450439
kubectl -n my-verticadb-operator delete pod test-runner --ignore-not-found || true
451440
kubectl -n my-verticadb-operator delete pod py-test-runner --ignore-not-found || true
452-
453441
echo "Deleting Keycloak pods & services..."
454442
kubectl delete deployment keycloak -n keycloak --ignore-not-found || true
455443
kubectl delete service keycloak -n keycloak --ignore-not-found || true
456444
kubectl delete ns keycloak --ignore-not-found || true
457-
458445
echo "Deleting VerticaDB and Operator..."
459446
kubectl delete verticadb verticadb-sample -n my-verticadb-operator --ignore-not-found || true
460447
helm uninstall vdb-op -n my-verticadb-operator || true
461448
kubectl delete ns my-verticadb-operator --ignore-not-found || true
462-
463449
echo "Deleting MinIO..."
464450
kubectl delete -f minio.yaml --ignore-not-found || true
465451
kubectl delete ns minio --ignore-not-found || true
466-
467452
echo "Deleting leftover services..."
468453
kubectl delete svc vertica-node-0 -n my-verticadb-operator --ignore-not-found || true
469454
kubectl delete svc vertica-node-1 -n my-verticadb-operator --ignore-not-found || true
470455
kubectl delete svc vertica-node-2 -n my-verticadb-operator --ignore-not-found || true
471-
472456
echo "Kubernetes resources cleanup done."
473-
474-
475457
- name: Delete KinD cluster
476458
if: always()
477459
run: |

0 commit comments

Comments
 (0)