Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds caching proxy example using HOMEBREW_ARTIFACT_DOMAIN #19131

Merged
merged 1 commit into from
Jan 22, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions docs/Tips-N'-Tricks.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,3 +121,18 @@ If you're using Homebrew on macOS Intel, you should also fix permissions afterwa
```sh
sudo chown -R "${USER}" /usr/local/etc
```

## Use a caching proxy or mirror for Homebrew bottles

You can configure Homebrew to retrieve bottles from a caching proxy or mirror.

For example, in JFrog's Artifactory, accessible at `https://artifacts.example.com`,
configure a new "remote" repository with `homebrew` as the "repository key" and `https://ghcr.io` as the URL.

Then, set these environment variables for Homebrew to retrieve from the caching proxy.

```sh
export HOMEBREW_ARTIFACT_DOMAIN=https://artifacts.example.com/artifactory/homebrew/
export HOMEBREW_ARTIFACT_DOMAIN_NO_FALLBACK=1
export HOMEBREW_DOCKER_REGISTRY_BASIC_AUTH_TOKEN="$(printf 'anonymous:' | base64)"
```
Loading