cephadm: add --registry-{password,username} options#35217
cephadm: add --registry-{password,username} options#35217tchaikov wants to merge 3 commits intoceph:masterfrom
Conversation
|
mypy: thanks for the PR! Just a few minor questions:
|
Yes, we need a way to pass these options down when cephadm is called by mgr/cephadm.
Agreed. But I like the cached registry better. if we cannot have it sooner, i will have to add this in qa/ as well.
I was not sure if it was an acceptable fix when working on this last night. But seems you are interested in this. And it’s actually a feature! not yet, i want to talk to @djgalloway to see if we can setup a http proxy to cache the images. my intention is to address https://tracker.ceph.com/issues/45631 ASAP as our tests are failing.
i know. that's why i want to logout to avoid security issues by calling "logout". do you have better idea how to keep this cached credentials around without hurting the performance? how about having a global instance of this decorator / context manager, and call "logout" in its destructor? |
24e44ea to
3917603
Compare
after a second thought, i am not sure about ir anymore. as "logout" command nukes all the cached credentials. no matter if they are added by cephadm or not.
meh, i removed it, as it's difficult to use a class to define a decorator, and to initialize this decorator requires a variable ( |
e2e881c to
2989288
Compare
allow user to log into container registry with the specified credentials. this helps user to address the issue if the registry is protected by authentication machinary. a global variable of `container_registry_credentials` is introduced. it is an instance of `ContainerRegistryCredentials` which serves as an decorator and also as a context manager. Fixes: https://tracker.ceph.com/issues/44886 Signed-off-by: Kefu Chai <kchai@redhat.com>
since we've dropped Python3 support in octopus, there is no need to keep the workaround for python2 anymore. Signed-off-by: Kefu Chai <kchai@redhat.com>
these options allow user to login to a container registry when, for instance, pulling images from configured container registry. with this change, mgr/cephadm passes these options down to cephadm, when deploying a daemon. Fixes: https://tracker.ceph.com/issues/44886 Signed-off-by: Kefu Chai <kchai@redhat.com>
2989288 to
a8d0341
Compare
|
Caching within cephadm itself won't help.
Also, how do you make Which makes me think. Having a solution where |
|
still this PR makes sense, if it is done right. @tchaikov you want to continue working on this? |
|
this PR was created to address the test failures. since it has been fixed by you, its priority is now lowered. i will come back once i have more bandwidth. |
allow user to log into container registry with the specified
credentials. this helps user to address the issue if the registry is
protected by authentication machinary.
Signed-off-by: Kefu Chai kchai@redhat.com
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard backendjenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume tox