This is an idea that came up at the Build a BinderHub workshop in Sheffield on 18 March.
Basically, we had a couple of people have difficulty building their BinderHub because they had typos in their configuration files.
The idea is that there could be either a script that you run locally, or (better) an integration to the BinderHub commands, that checks whether your secret information is correct:
Technical note: it is possible to check dockerhub credentials using curl and the docker api:
UNAME=drj11 # use you dockerhub id here
UPASS=xyzzy # your dockerhub password
curl -s -H "Content-Type: application/json" -X POST -d '{"username": "'${UNAME}'", "password": "'${UPASS}'"}' https://hub.docker.com/v2/users/login/
success will result in a large block of JSON (a valid login token!); failure results in
nice! maybe a good first step would be to write such a script for yourself, and then we can point to it as a part of the documentation. In the past we have often highlighted useful tools that others have created, but that for one reason or another we don’t “officially” support yet. What do you think?
If the way to check the credentials is a curl command like the above it could even be a callout in the zero-to-binderhub docs at the right place. It wouldn’t cover extracting it from the config file but maybe that is already a good enough start?