feat(registry-cache): add Docker Hub pull-through cache + dind mirror config

Deploy registry:2 as Docker Hub pull-through cache on chemavx-k8 (hostPort 5000,
ClusterIP 10.43.163.56:5000). Configures dind runner to use local mirror via
daemon.json to eliminate Docker Hub rate limit failures in CI/CD.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-22 11:35:36 +00:00
parent 25ea82f696
commit 0bf2e746dd
7 changed files with 211 additions and 0 deletions
@@ -0,0 +1,54 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: registry-cache
namespace: registry-cache
labels:
app: registry-cache
spec:
replicas: 1
selector:
matchLabels:
app: registry-cache
template:
metadata:
labels:
app: registry-cache
spec:
nodeSelector:
kubernetes.io/hostname: chemavx-k8
containers:
- name: registry
image: registry:2
ports:
- containerPort: 5000
hostPort: 5000
env:
- name: REGISTRY_PROXY_REMOTEURL
value: https://registry-1.docker.io
- name: REGISTRY_PROXY_USERNAME
value: ""
- name: REGISTRY_PROXY_PASSWORD
value: ""
- name: REGISTRY_STORAGE_DELETE_ENABLED
value: "true"
volumeMounts:
- name: registry-storage
mountPath: /var/lib/registry
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: "1"
memory: 1Gi
readinessProbe:
httpGet:
path: /v2/
port: 5000
initialDelaySeconds: 5
periodSeconds: 10
volumes:
- name: registry-storage
persistentVolumeClaim:
claimName: registry-cache-pvc
@@ -0,0 +1,9 @@
apiVersion: v1
kind: Namespace
metadata:
name: registry-cache
labels:
kubernetes.io/metadata.name: registry-cache
spec:
finalizers:
- kubernetes
+12
View File
@@ -0,0 +1,12 @@
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: registry-cache-pvc
namespace: registry-cache
spec:
accessModes:
- ReadWriteOnce
storageClassName: local-path
resources:
requests:
storage: 20Gi
@@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: registry-cache
namespace: registry-cache
spec:
selector:
app: registry-cache
ports:
- port: 5000
targetPort: 5000
protocol: TCP
type: ClusterIP