MySQLの実行環境を作ろうと思ってdocker pullしたら下記のようなエラー。
$ docker pull mysql:5.7
Error response from daemon: Get https://registry-1.docker.io/v2/library/mysql/manifests/5.7: unauthorized: incorrect username or password
どうやらdocker loginしないといけないようです。
$ docker login
Authenticating with existing credentials...
Stored credentials invalid or expired
Login with your Docker ID to push and pull images from Docker Hub. If you don't have a Docker ID, head over to https://hub.docker.com to create one.
Username (******@gmail.com): DockerHubのユーザ名
Password:
Login Succeeded
再度実行して無事pullできました
$ docker pull mysql:5.7
5.7: Pulling from library/mysql
...略
Status: Downloaded newer image for mysql:5.7