7

When docker login succeeds an auth token is put in ~/.dockercfg. We are considering deploying a .dockercfg file to EC2 instances to all running of containers against private repository images. The alternative would be to run docker login on the instances, but I would prefer to give instances an auth token as opposed to an account password.

How long do the tokens issued by docker.io last before they expire?

4

1 に答える 1

10

その「トークン」は、ユーザー名とパスワードが変更されない限り存続します。これは、ユーザー名とパスワードを base-64 でエンコードしたものです。「auth」値はサーバーから取得されるのではなく、 registry/auth.godockerのCLIによって生成されます。

于 2015-01-26T19:03:29.750 に答える