Skip to content

Zenith: Support GOPROXY from users in Go SDK #6077

Closed

Description

@sipsma

Right now users can't override goproxy which makes the engine unable to access go modules from e.g. corporate proxies.

There are obviously ways to just hack something together for this, but it would be greatly preferable to implement it as part of a more general concept of SDK settings.

In general, it probably makes sense for SDKs to accept configuration parameters and for those to usually be encoded in dagger.json.

However, goproxy in particular adds an extra layer of possible complication since it seems like something that shouldn't be encoded in dagger.json since it's unique to every caller, not module author.

It's possible we may need to also support user sdk configs provided at runtime, e.g. a ~/.config/dagger/defaults.json or something (just a strawman)

Activity

  1. nipuna-perera commented on Nov 6, 2023

    @nipuna-perera
    Contributor

    Thank you for opening this @sipsma ! I would like to add that besides GOPROXY, stuff like http_proxy, https_proxy and no_proxy are all important environment vars to be available within a module from a corporate standpoint. For my use case, http_proxy's are more important than GOPROXY.

    In today's world (non-zenith), whenever I need the proxies, I do something like this

    container.WithEnvVariable(os.Getenv("http_proxy"))

    So being able to programatically pass through the proxies to internal containers would be very useful.

  2. estesp commented on Mar 25, 2024

    @estesp

    @marcosnils looks like there is already an issue opened for this! just FYI per our discussion/hack time at KubeCon

  3. sipsma commented on Mar 25, 2024

    @sipsma
    ContributorAuthor

    Just FYI that fixes being discussed here #6599 include support for GOPROXY, so that's probably the right issue to track now (will leave this one open until the fix is merged)

  4. jedevc commented on Aug 29, 2025

    @jedevc
    Contributor

    Closing this out, since #7255 resolves this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions