|
16 | 16 | 2. [Push](#push) |
17 | 17 | 3. [Content Discovery](#content-discovery) |
18 | 18 | 4. [Content Management](#content-management) |
| 19 | +- [Proxying](#proxying) |
19 | 20 | - [Backwards Compatibility](#backwards-compatibility) |
20 | 21 | - [Unavailable Referrers API](#unavailable-referrers-api) |
21 | 22 | - [Upgrade Procedures](#upgrade-procedures) |
|
26 | 27 | - [Warnings](#warnings) |
27 | 28 | - [Appendix](#appendix) |
28 | 29 |
|
29 | | - |
30 | 30 | ## Overview |
31 | 31 |
|
32 | 32 | ### Introduction |
@@ -692,6 +692,23 @@ To delete a blob, perform a `DELETE` request to a path in the following format: |
692 | 692 | Upon success, the registry MUST respond with code `202 Accepted`. |
693 | 693 | If the blob is not found, a `404 Not Found` code MUST be returned. |
694 | 694 |
|
| 695 | +### Registry Proxying |
| 696 | + |
| 697 | +A registry MAY operate as a proxy to another registry to delegate functionality or implement additional functionality. |
| 698 | +An example of delegating functionality is proxying pull operations to another registry. |
| 699 | +An example of adding functionality is implementing a pull-through cache of pulls to another registry. |
| 700 | +When operating as a proxy, the `Host` header passed to the registry will be the host of the PROXY and NOT the host in the repository name used by the client. |
| 701 | +A `ns` query parameter on pull operations is OPTIONAL, but when used specifies the host in a repository name used by a client. |
| 702 | +The host in the repository name SHOULD be the first component of the full repository name used by a client. |
| 703 | +This host component in a repository name SHOULD be the registry host a client considers the primary source for a repository, however, a client MAY be configured to use a different host. |
| 704 | +This original host component used by the client is referred to as the source host in the API documentation. |
| 705 | +A proxy registry MAY use the `ns` query parameter to resolve an upstream registry host. |
| 706 | +A registry MAY choose to ignore the `ns` query parameter. |
| 707 | + |
| 708 | +A client SHOULD be aware of whether a registry host is being used is a proxy, such as when the `ns` query parameter differs from the `Host` header. |
| 709 | +A client SHOULD avoid sending `ns` query parameters to non-proxy registries. |
| 710 | +A client SHOULD NOT unintentionally send authorization credentials for an upstream registry to a proxy registry. |
| 711 | + |
695 | 712 | ### Backwards Compatibility |
696 | 713 |
|
697 | 714 | Client implementations MUST support registries that implement partial or older versions of the OCI Distribution Spec. |
|
0 commit comments