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
| `allowed_http_domains` | No | empty | Allowed HTTP domains (comma-separated, without port) |
207
-
| `allowed_https_domains` | No | empty | Allowed HTTPS domains (comma-separated, without port) |
206
+
| `allowed_http_domains` | No | empty | Allowed HTTP domains (comma-separated, without port). See [Domain matching patterns](#domain-matching-patterns) below |
207
+
| `allowed_https_domains` | No | empty | Allowed HTTPS domains (comma-separated, without port). See [Domain matching patterns](#domain-matching-patterns) below |
208
208
| `http_ports` | No | `80` | Comma-separated HTTP listen ports for the proxy |
209
209
| `https_ports` | No | `443` | Comma-separated HTTPS listen ports for the proxy |
210
210
| `port` | No | `1234` | BuildKit endpoint port on localhost |
211
211
212
+
##### Domain matching patterns
213
+
214
+
Domain values use nginx's [`map`](https://nginx.org/en/docs/http/ngx_http_map_module.html) directive with the `hostnames` parameter, supporting several patterns:
215
+
216
+
| Pattern | Example | Matches |
217
+
|---------|---------|---------|
218
+
| Exact domain | `registry.npmjs.org` | Only `registry.npmjs.org` |
| Regex | `~^.*\.amazonaws\.com$` | Full PCRE regex (prefix with `~`) |
223
+
212
224
#### Outputs
213
225
214
226
| Name | Description |
@@ -248,7 +260,6 @@ Pass this port to [`docker/setup-buildx-action`](https://github.com/docker/setup
248
260
#### Tips
249
261
250
262
- Start with audit mode to discover required domains, then switch to restrict mode.
251
-
- Wildcard domains are supported (e.g., `*.github.com` matches all subdomains of `github.com`).
252
263
- Separate HTTP and HTTPS domains — some services use different hosts for each protocol.
253
264
- Common package registries often use multiple domains (e.g., PyPI uses both `pypi.org` and `files.pythonhosted.org`).
254
265
- Some package managers download over plain HTTP (e.g., certain Debian mirrors). Add those domains to `allowed_http_domains` separately:
@@ -451,10 +462,6 @@ A: Yes. Just add your private registry's domain to `allowed_https_domains`.
451
462
452
463
A: In restrict mode, the build will fail with a clear error message. Run in audit mode first to discover all required domains.
453
464
454
-
**Q: Can I use wildcards in domain names?**
455
-
456
-
A: Yes. Prefix wildcards like `*.example.com` are supported and will match all subdomains (e.g., `sub.example.com`, `deep.sub.example.com`). Note that `*.example.com` does not match `example.com` itself—add both if needed. Suffix wildcards (e.g., `example.*`) are not supported.
457
-
458
465
**Q: Do I need to clean up the buildcage container?**
459
466
460
467
A: No. The container is automatically removed when the GitHub Actions job completes.
0 commit comments