fix(ci): skip immutable PVCs and job template in deploy apply

training-data-pvc is immutable (already bound with ReadWriteOnce),
and job-template.yaml has placeholder names (MODEL/TIMESTAMP) that
fail k8s validation. Only apply service deployments and binary cache
PVCs in the deploy job.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
jgrusewski
2026-02-28 19:33:35 +01:00
parent 0d4c90acbe
commit e6d0abccf0

View File

@@ -1413,8 +1413,10 @@ deploy:
# S3 binary share: services use generic runtime image + initContainer to fetch binaries from S3.
# Deploy = apply K8s manifests (picks up YAML changes) + rollout restart (fetch new binaries).
- echo "Deploying ${CI_COMMIT_SHA}..."
# Apply all service manifests (idempotent — picks up any YAML changes)
- kubectl apply -f infra/k8s/services/ -f infra/k8s/storage/ -f infra/k8s/training/
# Apply service deployments and binary cache PVCs (idempotent — picks up any YAML changes)
# Skip training/job-template.yaml (placeholder names, not directly applicable)
# Skip storage/training-data-pv.yaml (PVC spec immutable after creation)
- kubectl apply -f infra/k8s/services/ -f infra/k8s/storage/binary-cache-pvcs.yaml
# Rolling restart triggers initContainers to fetch latest binaries from S3
- |
for svc in trading-service api-gateway broker-gateway \