parent
67fb5505af
commit
393eff3504
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 45m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://registry-1.docker.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: dockerhub-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: dockerhub
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: dockerhub
|
||||
serviceName: dockerhub
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: dockerhub
|
||||
spec:
|
||||
containers:
|
||||
- name: dockerhub
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: dockerhub
|
||||
volumeMounts:
|
||||
- name: dockerhub-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: dockerhub-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: dockerhub-cnf
|
||||
configMap:
|
||||
name: dockerhub-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: dockerhub-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: dockerhub
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: dockerhub
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 1m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://gcr.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: gcr-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: gcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: gcr
|
||||
serviceName: gcr
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: gcr
|
||||
spec:
|
||||
containers:
|
||||
- name: gcr
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: gcr
|
||||
volumeMounts:
|
||||
- name: gcr-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: gcr-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: gcr-cnf
|
||||
configMap:
|
||||
name: gcr-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: gcr-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: gcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: gcr
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 1m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://ghcr.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: ghcr-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: ghcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: ghcr
|
||||
serviceName: ghcr
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: ghcr
|
||||
spec:
|
||||
containers:
|
||||
- name: ghcr
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: ghcr
|
||||
volumeMounts:
|
||||
- name: ghcr-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: ghcr-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: ghcr-cnf
|
||||
configMap:
|
||||
name: ghcr-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: ghcr-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: ghcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: ghcr
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: registry-ingress
|
||||
namespace: registry
|
||||
annotations:
|
||||
kubernetes.io/ingress.class: "nginx"
|
||||
nginx.ingress.kubernetes.io/ssl-passthrough: "true"
|
||||
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
|
||||
spec:
|
||||
rules:
|
||||
- host: "quay.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: quay
|
||||
port:
|
||||
number: 5000
|
||||
- host: "registryk8s.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: registryk8s
|
||||
port:
|
||||
number: 5000
|
||||
- host: "gcr.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: gcr
|
||||
port:
|
||||
number: 5000
|
||||
- host: "ghcr.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: ghcr
|
||||
port:
|
||||
number: 5000
|
||||
- host: "k8sgcr.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: k8sgcr
|
||||
port:
|
||||
number: 5000
|
||||
- host: "hub.example.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: "/"
|
||||
backend:
|
||||
service:
|
||||
name: dockerhub
|
||||
port:
|
||||
number: 5000
|
||||
tls:
|
||||
- hosts:
|
||||
- example.com
|
||||
secretName: example.com-tls
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 1m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://k8s.gcr.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: k8sgcr-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: k8sgcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: k8sgcr
|
||||
serviceName: k8sgcr
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: k8sgcr
|
||||
spec:
|
||||
containers:
|
||||
- name: k8sgcr
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: k8sgcr
|
||||
volumeMounts:
|
||||
- name: k8sgcr-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: k8sgcr-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: k8sgcr-cnf
|
||||
configMap:
|
||||
name: k8sgcr-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: k8sgcr-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: k8sgcr
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: k8sgcr
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
resources:
|
||||
- registryk8s
|
||||
- quay
|
||||
- dockerhub
|
||||
- gcr
|
||||
- ghcr
|
||||
- k8sgcr
|
||||
- ingress.yaml
|
||||
|
||||
namespace: registry
|
||||
|
||||
images:
|
||||
- name: registry
|
||||
newTag: 2.8.3
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 1m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://quay.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: quay-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: quay
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: quay
|
||||
serviceName: quay
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: quay
|
||||
spec:
|
||||
containers:
|
||||
- name: quay
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: quay
|
||||
volumeMounts:
|
||||
- name: quay-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: quay-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: quay-cnf
|
||||
configMap:
|
||||
name: quay-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: quay-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: quay
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: quay
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
version: 0.1
|
||||
storage:
|
||||
filesystem:
|
||||
rootdirectory: /var/lib/registry
|
||||
delete:
|
||||
enabled: true
|
||||
maintenance:
|
||||
uploadpurging:
|
||||
enabled: true
|
||||
age: 168h
|
||||
dryrun: false
|
||||
interval: 1m
|
||||
http:
|
||||
addr: 0.0.0.0:5000
|
||||
proxy:
|
||||
remoteurl: https://registry.k8s.io
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
resources:
|
||||
- sts.yaml
|
||||
- svc.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: registryk8s-cnf
|
||||
files:
|
||||
- config.yml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: registryk8s
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: registryk8s
|
||||
serviceName: registryk8s
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: registryk8s
|
||||
spec:
|
||||
containers:
|
||||
- name: registryk8s
|
||||
image: registry:2.8.1
|
||||
ports:
|
||||
- containerPort: 5000
|
||||
name: registryk8s
|
||||
volumeMounts:
|
||||
- name: registryk8s-data
|
||||
mountPath: /var/lib/registry
|
||||
- name: timezone
|
||||
mountPath: /etc/localtime
|
||||
readOnly: true
|
||||
- name: registryk8s-cnf
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
subPath: config.yml
|
||||
volumes:
|
||||
- name: registryk8s-cnf
|
||||
configMap:
|
||||
name: registryk8s-cnf
|
||||
- name: timezone
|
||||
hostPath:
|
||||
path: /usr/share/zoneinfo/Asia/Shanghai
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: registryk8s-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: registryk8s
|
||||
namespace: registry
|
||||
spec:
|
||||
selector:
|
||||
app: registryk8s
|
||||
ports:
|
||||
- port: 5000
|
||||
targetPort: 5000
|
||||
Loading…
Reference in New Issue