Self-hosted mirror for the Terraform Provider Registry and HashiCorp tool binaries
813
A fast, robust, and flexible self-hosted mirror for the Terraform Provider Registry and HashiCorp tool binaries. Designed for air-gapped, enterprise, and CI/CD environments, it supports advanced filtering, Prometheus metrics, and multiple deployment options.
/metrics endpoint for monitoring.index.json and .tf-mirror-metadata.json compatible with Terraform.docker run --rm -v $(pwd)/data:/data docker.io/ademidovx/tf-mirror:latest \
--mode downloader --download-path /data --provider-filter=hashicorp/aws
docker run --rm -p 8080:8080 -v $(pwd)/data:/data docker.io/ademidovx/tf-mirror:latest \
--mode server --data-path /data --listen-port 8080
| Option | Description |
|---|---|
| --mode | downloader or server |
| --download-path | Directory for downloads (downloader mode) |
| --data-path | Directory to serve (server mode) |
| --provider-filter | Comma-separated providers (e.g. hashicorp/aws) |
| --platform-filter | Comma-separated platforms (e.g. linux_amd64) |
| --download-binaries | Comma-separated tools (e.g. terraform>1.6.0,consul>1.21.3) |
| --check-period | Check interval in hours (downloader) |
| --max-attempts | Max download attempts |
| --download-timeout | Timeout per download (seconds) |
| --listen-host | Server listen address |
| --listen-port | Server port (default: 80) |
| --hostname | Server hostname (optional) |
| --enable-tls | Enable HTTPS |
| --tls-crt | TLS certificate path |
| --tls-key | TLS key path |
| --debug | Enable debug logging |
| --help | Show help |
| --version | Show version |
| Variable | Description (same as CLI unless noted) |
|---|---|
| TF_MIRROR_MODE | Mode: downloader/server |
| PROXY | Proxy URL |
| CHECK_PERIOD | Check period |
| DOWNLOAD_PATH | Download path |
| PROVIDER_FILTER | Provider filter |
| PLATFORM_FILTER | Platform filter |
| MAX_ATTEMPTS | Max attempts |
| DOWNLOAD_TIMEOUT | Download timeout |
| DOWNLOAD_BINARIES | Binaries filter |
| DATA_PATH | Data path (server) |
| LISTEN_HOST | Listen host |
| LISTEN_PORT | Listen port |
| HOSTNAME | Hostname |
| ENABLE_TLS | Enable TLS |
| TLS_CRT | TLS cert path |
| TLS_KEY | TLS key path |
| DEBUG | Debug logging |
Content type
Helm
Digest
sha256:e2e1b3036…
Size
4.5 kB
Last updated
10 months ago
helm pull oci://registry-1.docker.io/ademidovx/tf-mirror --version 0.1.0