From cdf4bdb511eef66f2e25d1aac5061e2309efa446 Mon Sep 17 00:00:00 2001 From: Adrien Folie Date: Sat, 18 Apr 2015 02:01:05 +0200 Subject: [PATCH] add docs for authconfig base64 encoded key --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index a22db56..659b279 100644 --- a/README.md +++ b/README.md @@ -212,6 +212,14 @@ docker.pull('tag', {'authconfig': auth}, function (err, stream) { //... }); ``` + +If you already have a base64 encoded auth object, you can use it directly: + +```js +var auth = { key: 'yJ1J2ZXJhZGRyZXNzIjoitZSI6Im4OCIsImF1dGgiOiIiLCJlbWFpbCI6ImZvbGllLmFkcmc2VybmF0iLCJzZX5jb2aHR0cHM6Ly9pbmRleC5kb2NrZXIuaW8vdZvbGllYSIsInBhc3N3b3JkIjoiRGVjZW1icmUjEvIn0=' } +``` + + ## Helper functions * `followProgress` - allows to fire a callback only in the end of a stream based process. (build, pull, ...)