distribution: registry config problem
If I set an env config, registry won’t parse the config in my config file.
env config:
REGISTRY_STORAGE: s3
REGISTRY_STORAGE_S3_ACCESSKEY: ${REGISTRY_STORAGE_S3_ACCESSKEY}
REGISTRY_STORAGE_S3_SECRETKEY: ${REGISTRY_STORAGE_S3_SECRETKEY}
REGISTRY_STORAGE_S3_BUCKET: ${REGISTRY_STORAGE_S3_BUCKET}
REGISTRY_STORAGE_S3_REGION: ${REGISTRY_STORAGE_S3_REGION}
# REGISTRY_STORAGE_CACHE_BLOBDESCRIPTOR: redis
config file:
version: 0.1
storage:
filesystem:
rootdirectory: /var/lib/registry
delete:
enabled: true
cache:
blobdescriptor: redis
http:
addr: 0.0.0.0:5000
debug:
addr: 0.0.0.0:5001
redis:
addr: redis:6379
If I turn on the comment, the registry will not use redis as its blob descriptor:
registry_1 | time="2017-12-06T06:32:34Z" level=info msg="Starting upload purge in 53m0s" go.version=go1.7.6 instance.id=d2ee585b-e082-4d4c-a435-bd62a8711af9 version=v2.6.2
registry_1 | time="2017-12-06T06:32:34Z" level=info msg="listening on [::]:5000, tls" go.version=go1.7.6 instance.id=d2ee585b-e082-4d4c-a435-bd62a8711af9 version=v2.6.2
If I turn off the comment, it works:
registry_1 | time="2017-12-06T06:27:48Z" level=info msg="Starting upload purge in 58m0s" go.version=go1.7.6 instance.id=b96d0204-25b2-4c1f-bbba-1007ea47aa5e version=v2.6.2
registry_1 | time="2017-12-06T06:27:48Z" level=info msg="using redis blob descriptor cache" go.version=go1.7.6 instance.id=b96d0204-25b2-4c1f-bbba-1007ea47aa5e version=v2.6.2
registry_1 | time="2017-12-06T06:27:48Z" level=info msg="listening on [::]:5000, tls" go.version=go1.7.6 instance.id=b96d0204-25b2-4c1f-bbba-1007ea47aa5e version=v2.6.2
But interestingly, registry use the delete.enable part and ignored the cache.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 17 (3 by maintainers)
Commits related to this issue
- fix issue #2464 combine parsed storage config with config file — committed to wrfly/distribution by wrfly 7 years ago
- fix issue #2464 combine parsed storage config with config file Signed-off-by: fushouguo <shouguo.fu@nexusguard.com> — committed to wrfly/distribution by wrfly 7 years ago
- fix issue #2464 combine parsed storage config with config file Signed-off-by: wrfly <mr.wrfly@gmail.com> — committed to wrfly/distribution by wrfly 7 years ago
@wrfly the order doesn’t matter - if you “merge”, you still end-up with multiple (conflicting) backend declarations.