Go
Overview
Your Go dependencies from proxy.golang.org, cached and managed through Fly for faster, consistent builds.
Go modules is the dependency management system for Go projects. JFrog Fly proxies Go modules from proxy.golang.org (the official Go module mirror). By configuring Fly, all your dependencies are cached and managed through Fly, providing faster downloads and unified dependency management.
Supported Clients
JFrog Fly supports Go modules with:
- Go CLI (
go get,go mod download) - The standard Go toolchain for managing dependencies
Download Module
With Fly App
Activate Go in your Fly App to configure your GOPROXY to use Fly. All modules from proxy.golang.org will be cached and managed through Fly:
go get <module-path>Or download all dependencies:
go mod downloadManual Configuration
1. Generate an access token in Fly Token Management
2. Configure GOPROXY to route through Fly:
go env -w GOPROXY=https://<your-fly-username>:<your-fly-token>@<your-fly-subdomain>.jfrog.io/artifactory/api/go/go,directTip
The ,direct fallback ensures that if a module is not found in Fly, Go will attempt to fetch it directly from the source. This is the recommended configuration.
3. Download module:
go get <module-path>All modules will be fetched from proxy.golang.org through Fly and cached for future use.
Download Modules with CI
To download Go modules with CI, update your GitHub Actions workflow to include the Fly action.
Simply ask your coding agent: “Configure my workflows with Fly” and Fly MCP will configure your GitHub Actions workflow yml file, as follows:
1. Add permissions (top level, after on:):
permissions:
contents: read
id-token: write2. Add Fly Action (after actions/setup-go, before go commands):
- uses: jfrog/fly-action@v1 # Setup Fly package managersGitHub Action Example
name: Build Go Application
on:
push:
branches: [main]
permissions:
contents: read
id-token: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
- uses: jfrog/fly-action@v1 # Setup Fly package managers
- run: go mod download # Modules from Fly registry
- run: go build -v ./...
- run: go test -v ./...Back to Package Managers →