I’m running into the same problem, but as a service which relies on kubernetes-secrets. My env vars are populated, the settings stanza doesn’t affect my pull tho.
the syntax in your second example does not match what was described in How to pull private images with 1.0. Also note that are expected to store a json string with credentials, not a username and password (this is also described in the link I posted).
how can i get that token for the json file? (My record is azure).
In drone version 0.8 in the UI you could register the following Registry Address, Resgistry Username, Registry Password. (Now in version 1.0 this option does not appear)
I usually access docker login_server -username registry_username -password regstry_passwod
You can use the docker login [registry] command on a system with docker, then check ~/.docker/config.json file for the token. docker login will prompt you for username and password.
I think perhaps there is still a misunderstanding … you should upload your json file as a secret, and then reference the named secret in image_pull_secrets. Drone expects the full json string as the secret value.
You can find the json file at ~/.docker/config.json after running docker login. I recommend running this command on a linux machine.
{
“auths”: {
“https://xxyyregistry.azurecr.io”: {
“auth”: “cmVnaXN0cnlfdXNlcm5hbWU6cmVnaXN0cnlfcGFzc3dvcmQK”
}
}
}
Question:
What is the path where I must place my json file in drone so that I can take the changes?
I can confirm it works when properly configured – we are using this internally. You can audit the source code and unit tests to learn more about how this behaves: