balena-io / balena-cli

The official balena CLI tool.
Apache License 2.0
452 stars 138 forks source link

balena push --registry-secrets fails when certain passwords are used #2233

Open pdcastro opened 3 years ago

pdcastro commented 3 years ago

As originally reported by @notnamed in (restricted access): https://www.flowdock.com/app/rulemotion/public-s-community/threads/DLD3YK893e1msi1uG0s2AAzMVZh

$ balena push myApp --registry-secrets secrets.yml
...
[debug] handling message: {"message":"\u001b[31m[Error]\u001b[39m        Error: pull access denied for balenajordan/test, repository does not exist or may require 'docker login': denied: requested access to the resource is denied","isError":true}
[Error]        Error: pull access denied for balenajordan/test, repository does not exist or may require 'docker login': denied: requested access to the resource is denied

where balenajordan/test is private Docker Hub repo, and the docker-compose.yml file contains image: balenajordan/test, or the Dockerfile contains FROM balenajordan/test, and the private repo password is in the format:

secrets.yml

'':
    username: balena
    password: '3g6~TX_2qmCW4HF8N~OEzjp.R0X5BLi..S'

The actual password was different, but contained the non-letter, non-numeric characters above. The single quotes are not part of the password. It was found that changing the password avoided the error.

Known workaround Use a different password. It is not yet clear whether the problem regards specific characters or the password length or something else, but it was found that changing the password avoided the error.

jellyfish-bot commented 2 years ago

[rcooke-warwick] This issue has attached support thread https://jel.ly.fish/d861409b-ca1e-4292-8cc9-34bc2533e64b