registry: Add redis as cache

This commit is contained in:
Kacper Donat 2021-06-04 09:56:09 +02:00
parent 7d14d9b6e7
commit 586e1653b7
2 changed files with 17 additions and 7 deletions

View File

@ -1,21 +1,24 @@
version: 0.1
log:
level: debug
fields:
service: registry
storage:
cache:
blobdescriptor: inmemory
blobdescriptor: redis
{{ registry_storage|to_nice_yaml(indent=2, width=140)|indent(2) }}
redis:
addr: redis:6379
http:
addr: :5000
headers:
X-Content-Type-Options: [nosniff]
auth:
htpasswd:
realm: basic-realm
realm: Kadet's private registry
path: /etc/docker/registry/htpasswd
health:
storagedriver:
enabled: true
interval: 10s
threshold: 3

View File

@ -1,6 +1,13 @@
version: "{{ compose_version }}"
services:
redis:
image: redis:latest
deploy:
resources:
limits:
memory: 256M
registry:
image: registry:2
secrets: