perf(ci): switch sccache from S3 to local block storage PVC
- Create 20Gi sccache-pvc (scw-bssd) for fast local cache hits - Mount at /mnt/sccache in CI build pods via runner helm values - Use SCCACHE_DIR instead of SCCACHE_BUCKET for check/test jobs - Kaniko builds keep S3 sccache (can't mount PVCs in Kaniko) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -19,12 +19,12 @@ variables:
|
||||
JWT_SECRET: "CiTestSecret_Kx7mP9nR2sW5vY8bC3fG6jH1kL4pQ7tZ0uN9dM5eV8xS2wT6yA4zB_64chars_min"
|
||||
# Training data on block storage PVC (mounted at /mnt/training-data by runner)
|
||||
FOXHUNT_DATA_DIR: "/mnt/training-data/futures-baseline"
|
||||
SCCACHE_BUCKET: $SCCACHE_BUCKET
|
||||
SCCACHE_ENDPOINT: $SCCACHE_ENDPOINT
|
||||
SCCACHE_S3_USE_SSL: "true"
|
||||
# sccache on local block storage PVC (mounted at /mnt/sccache by runner)
|
||||
SCCACHE_DIR: "/mnt/sccache"
|
||||
RUSTC_WRAPPER: /usr/local/bin/sccache
|
||||
# S3 credentials still needed for Kaniko (Dockerfile) sccache
|
||||
AWS_ACCESS_KEY_ID: $SCW_ACCESS_KEY
|
||||
AWS_SECRET_ACCESS_KEY: $SCW_SECRET_KEY
|
||||
RUSTC_WRAPPER: /usr/local/bin/sccache
|
||||
# CI builder image on Scaleway Container Registry (reachable by Kapsule nodes)
|
||||
CI_BUILDER_IMAGE: rg.fr-par.scw.cloud/foxhunt-ci/ci-builder:latest
|
||||
# Scaleway Container Registry for service images
|
||||
|
||||
@@ -52,6 +52,11 @@ runners:
|
||||
name = "training-data-pvc"
|
||||
mount_path = "/mnt/training-data"
|
||||
read_only = true
|
||||
# sccache on local block storage — faster than S3 for cache hits
|
||||
[[runners.kubernetes.volumes.pvc]]
|
||||
name = "sccache-pvc"
|
||||
mount_path = "/mnt/sccache"
|
||||
read_only = false
|
||||
|
||||
# Runner tags for job matching
|
||||
tags: "kapsule,rust,docker,gpu"
|
||||
|
||||
16
infra/k8s/storage/sccache-pvc.yaml
Normal file
16
infra/k8s/storage/sccache-pvc.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: sccache-pvc
|
||||
namespace: foxhunt
|
||||
labels:
|
||||
app.kubernetes.io/name: sccache
|
||||
app.kubernetes.io/part-of: foxhunt
|
||||
app.kubernetes.io/component: ci
|
||||
spec:
|
||||
storageClassName: scw-bssd
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 20Gi
|
||||
Reference in New Issue
Block a user