You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+18-3Lines changed: 18 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,12 +21,13 @@ for this to work it requires inserting a root CA certificate into system trusted
21
21
- Map volume `/docker_mirror_cache` for up to 32gb of cached images from all registries
22
22
- Map volume `/ca`, the proxy will store the CA certificate here across restarts
23
23
- Env `REGISTRIES`: space separated list of registries to cache; no need to include Docker Hub, its already there.
24
-
- Env `AUTH_REGISTRIES`: space separated list of `hostname:username:password` authentication info.
24
+
- Env `AUTH_REGISTRIES`: space separated list of `hostname:username:password` authentication info.
25
25
-`hostname`s listed here should be listed in the REGISTRIES environment as well, so they can be intercepted.
26
26
- For Docker Hub authentication, `hostname` should be `auth.docker.io`, username should NOT be an email, use the regular username.
27
27
- For regular registry auth (HTTP Basic), `hostname` here should be the same... unless your registry uses a different auth server. This should work for quay.io also, but I have no way to test.
28
-
- For Google Container Registry (GCR), username should be `_json_key` and the password should be the contents of the service account JSON. Check out [GCR docs](https://cloud.google.com/container-registry/docs/advanced-authentication#json_key_file)
29
-
28
+
- Env `AUTH_REGISTRIES_DELIMITER` to change the separator between authentication info. By default, a space: "``". If you use keys that contain spaces (as with Google Cloud Registry), you should update this variable, e.g. setting it to `AUTH_REGISTRIES_DELIMITER=";;;"`. In that case, `AUTH_REGISTRIES` could contain something like `registry1.com:user1:pass1;;;registry2.com:user2:pass2`.
29
+
- Env `AUTH_REGISTRY_DELIMITER` to change the separator between authentication info *parts*. By default, a colon: "`:`". If you use keys that contain single colons, you should update this variable, e.g. setting it to `AUTH_REGISTRIES_DELIMITER=":::"`. In that case, `AUTH_REGISTRIES` could contain something like `registry1.com:::user1:::pass1 registry2.com:::user2:::pass2`.
30
+
- For Google Container Registry (GCR), username should be `_json_key` and the password should be the contents of the service account JSON. Check out [GCR docs](https://cloud.google.com/container-registry/docs/advanced-authentication#json_key_file). The service account key is in JSON format, it contains spaces ("``") and colons ("`:`"). To be able to use GCR you should set `AUTH_REGISTRIES_DELIMITER` to something different than space (e.g. `AUTH_REGISTRIES_DELIMITER=";;;"`) and `AUTH_REGISTRY_DELIMITER` to something different than a single colon (e.g. `AUTH_REGISTRY_DELIMITER=":::"`).
30
31
31
32
```bash
32
33
docker run --rm --name docker_registry_proxy -it \
0 commit comments