You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using a self hosted registry, credentials are provided which are used to retrieve a token. If the registry does not implement a token service, the endpoint returns a 404 and version-checker cannot authenticate to the registry.
$ k plogs -n version-checker -p version-checker-7db59c4996-8hj99 -c version-checker
...
error: failed to setup image registry clients: failed to create selfhosted client "http://docker-registry.registry.svc.cluster.local:5000": failed to setup token auth (404): 404 page not found
This issue has been automatically marked as stale because it has not had
any activity in the last 90 days. It will be closed if no further activity
occurs. Thank you for your contributions.
Describe the bug
When using a self hosted registry, credentials are provided which are used to retrieve a token. If the registry does not implement a token service, the endpoint returns a 404 and version-checker cannot authenticate to the registry.
$ k plogs -n version-checker -p version-checker-7db59c4996-8hj99 -c version-checker ... error: failed to setup image registry clients: failed to create selfhosted client "http://docker-registry.registry.svc.cluster.local:5000": failed to setup token auth (404): 404 page not found
$ curl -i http://XXXXXX:XXXXXX@localhost:30000/v2/token HTTP/1.1 404 Not Found Content-Type: text/plain; charset=utf-8 Docker-Distribution-Api-Version: registry/2.0 X-Content-Type-Options: nosniff Date: Thu, 29 Aug 2024 08:33:26 GMT Content-Length: 19 404 page not found
This could be an edge case, and there should be a token endpoint in which case a 404 is the right response and basic auth shouldn't be used.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Basic auth should be used when token endpoint returns 404 so version-checker can authenticate with the registry.
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: