lasthourcloud/templates/compose/docker-registry.yaml

50 lines
1.5 KiB
YAML
Raw Normal View History

# documentation: https://docs.docker.com/registry/
# slogan: The Docker Registry is a stateless, highly scalable server side application that stores and lets you distribute Docker images.
# tags: registry,images,docker
2024-02-20 14:07:12 +00:00
# logo: svgs/docker-registry.png
services:
registry:
image: registry:2
environment:
- SERVICE_FQDN_REGISTRY
- REGISTRY_AUTH=htpasswd
- REGISTRY_AUTH_HTPASSWD_REALM=Registry
- REGISTRY_AUTH_HTPASSWD_PATH=/auth/registry.password
- REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY=/data
volumes:
- type: bind
source: ./auth/registry.password
target: /auth/registry.password
isDirectory: false
content: >-
testuser:$2y$05$/o2JvmI2bhExXIt6Oqxa7ekYB7v3scj1wFEf6tBslJvJOMoPQL.Gy
- type: bind
source: ./config/config.yml
target: /etc/docker/registry/config.yml
isDirectory: false
content: >-
version: 0.1
log:
fields:
service: registry
storage:
cache:
blobdescriptor: inmemory
filesystem:
rootdirectory: /var/lib/registry
http:
addr: :5000
headers:
X-Content-Type-Options: [nosniff]
health:
storagedriver:
enabled: true
interval: 10s
threshold: 3
- type: bind
source: ./data
target: /data
isDirectory: true