Giter Club home page Giter Club logo

Comments (3)

rarkins avatar rarkins commented on August 29, 2024

To properly test proxy, we need a container running without any direct internet access.

This seems relevant: https://forums.docker.com/t/internal-network-between-containers-without-external-network-access/41751/9

Found via https://stackoverflow.com/questions/39913757/restrict-internet-access-docker-container

In theory there could be different proxies during build and during deployment so need to think how that would work. Our ideal is that it simply needs HTTP_PROXY passed in, e.g.

Build: docker build --build-arg HTTP_PROXY=http://10.0.0.1 . -t my_image

Run: docker up -d -e HTTP_PROXY=https://proxy.company.com my_image

We can address it this way:

  • For tools (build or runtime) which respect HTTP_PROXY then we do nothing additional
  • For tools which can use a proxy but need it provided a different way (e.g. config file, or CLI arg) then we perhaps need to wrap their CLI command to prepare the proxy config before calling the actual command
  • For tools which don't support proxy, we need to find alternatives or document that it's impossible. Ideally zero of those in build.

from base.

rarkins avatar rarkins commented on August 29, 2024

We probably need to think about DNS too. Maybe the proxy container will also be the DNS forwarder.

from base.

viceice avatar viceice commented on August 29, 2024

at least apt needs a special handling on install, which we support via APT_HTTP_PROXY env. thats already tested well. also ci tests are using the apt proxy

from base.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.