Files
kubernetes.doku/Distribution/RegistryDeployment.yaml
T
2024-02-19 11:02:14 +01:00

54 lines
1.2 KiB
YAML

# RegistryDeployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
run: registry
name: registry
namespace: distribution
spec:
replicas: 1
selector:
matchLabels:
run: registry
template:
metadata:
labels:
run: registry
spec:
nodeSelector:
node-type: worker
containers:
- name: registry
image: registry:2
ports:
- containerPort: 5000
env:
- name: REGISTRY_HTTP_TLS_CERTIFICATE
value: "/certs/tls.crt"
- name: REGISTRY_HTTP_TLS_KEY
value: "/certs/tls.key"
volumeMounts:
- name: registry-certs
mountPath: "/certs"
readOnly: true
- name: registry-data
mountPath: /var/lib/registry
subPath: registry
volumes:
- name: registry-certs
secret:
secretName: registry-cert
# - name: registry-data
# persistentVolumeClaim:
# claimName: distribution-pvc
volumeClaimTemplates:
- metadata:
name: registry-data
spec:
accessModes:
- ReadWriteOnce
storageClassName: distribution-sc
resources:
requests:
storage: 100Gi