---
title: "ezgh registry cache-rules"
description: "Pull-through cache rules: Docker Hub images through your registry."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ezgh registry cache-rules

{/* Generated by ezgh-cli's internal/tools/clidocs from the ezgh command tree. Don't edit: change the command's help in ezgh-cli and regenerate. */}

```sh
ezgh registry cache-rules <command>
```

A pull-through cache rule maps a prefix on the project's registry host to Docker Hub. The first pull of &lt;host&gt;/&lt;prefix&gt;/&lt;namespace&gt;/&lt;repository&gt; fetches the image with the rule's credentials (an EZGH Secrets secret granted to the rule) and stores it in the project; later pulls are served from that copy, and tags are rechecked once they're a day old. A rule is given by prefix, ID or slug (ptc\_…).

Part of [`ezgh registry`](/cli/reference/registry).

## Flags

This command also takes the [global flags](/cli/reference#global-flags).

## Subcommands

| Command | Description |
| --- | --- |
| [`ezgh registry cache-rules create`](/cli/reference/registry-cache-rules-create) | Create a pull-through cache rule and grant it its credentials |
| [`ezgh registry cache-rules delete`](/cli/reference/registry-cache-rules-delete) | Delete a pull-through cache rule and every repository it cached |
| [`ezgh registry cache-rules failures`](/cli/reference/registry-cache-rules-failures) | List a pull-through cache rule's recent failures |
| [`ezgh registry cache-rules get`](/cli/reference/registry-cache-rules-get) | Show a pull-through cache rule |
| [`ezgh registry cache-rules list`](/cli/reference/registry-cache-rules-list) | List the project's pull-through cache rules |
| [`ezgh registry cache-rules update`](/cli/reference/registry-cache-rules-update) | Change a pull-through cache rule's credentials or description |

Source: https://docs.ezghcloud.com/cli/reference/registry-cache-rules/index.mdx
