Thanks for the Tips. I have tried your curl call with the Token, and here is the response:
curl --head -H "Authorization: Bearer $TOKEN" https://registry-1.docker.io/v2/ratelimitpreview/test/manifests/latest
HTTP/1.1 200 OK
content-length: 527
content-type: application/vnd.docker.distribution.manifest.v2+json
docker-content-digest: sha256:c2d41d2ba6d8b7b4a3ffec621578eb4d9a0909df29dfa2f6fd8a2e5fd0836aed
docker-distribution-api-version: registry/2.0
etag: "sha256:c2d41d2ba6d8b7b4a3ffec621578eb4d9a0909df29dfa2f6fd8a2e5fd0836aed"
date: Tue, 05 Aug 2025 19:45:42 GMT
strict-transport-security: max-age=31536000
ratelimit-limit: 100;w=21600
ratelimit-remaining: 84;w=21600
docker-ratelimit-source: 96.45.36.254
84/100, still good ? Anyway, I have found a work around for my case.
-
login to docker hub with my gmail account => profile => setting => personal access tokens = > To create a new token
-
Using this command to create a secret:
kubectl create secret docker-registry dockerhub-secret --docker-username=<user_id> --docker-password=<token_value> --docker-email=<email>
- In my k8s project, I have added this piece:
imagePullSecrets:
- name: dockerhub-secret
It seems working now in my k8s deployment.
Thanks for the help.