Skip to content

modules: ability to use local $CUE_CACHE_DIR/mod/download as a virtual registry #3846

@myitcv

Description

@myitcv

What version of CUE are you using (cue version)?

$ cue version
cue version v0.13.0-alpha.1.0.20250324111431-1eccc4649d73

go version go1.24.0
      -buildmode exe
       -compiler gc
  DefaultGODEBUG gotestjsonbuildtext=1,multipathtcp=0,randseednop=0,rsa1024min=0,tlsmlkem=0,x509rsacrt=0,x509usepolicies=0
     CGO_ENABLED 1
          GOARCH arm64
            GOOS linux
         GOARM64 v8.0
             vcs git
    vcs.revision 1eccc4649d732a422003716b51b130bcd134a938
        vcs.time 2025-03-24T11:14:31Z
    vcs.modified false
cue.lang.version v0.13.0

Is your feature request related to a problem? Please describe.

Go has the ability to set:

GOPROXY=file://$(go env GOMODCACHE)/cache/download

in order that all module-related commands use the local filesystem as a virtual proxy. i.e. no network access. Even queries like @latest work against the local filesystem virtual proxy.

Describe the solution you'd like

A similar feature in CUE. Whether via CUE_REGISTRY or otherwise.

Describe alternatives you've considered

Updating cue mod registry to have a flag that uses the effective CUE_CACHE_DIR as a read-only source of modules.

Additional context

n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    FeatureRequestNew feature or requestmodulesIssues related to CUE modules and the experimental implementation

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions