Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

566
Visualizações
Configure Docker to use a proxy server

I have installed docker on windows , when I try to run hello-world for testing on docker. I get following error

Unable to find image

My computer is using proxy server for communication. I need to configure that server in the docker. I know proxy server address and port. Where I need to update this setting. I tried using https://docs.docker.com/network/proxy/#set-the-environment-variables-manually. It is not working.

over 4 years ago · Santiago Trujillo
3 Respostas
Responde à pergunta

0

Try setting the proxy. Right click on the docker icon in system tray, go to settings, proxy and add the below settings:

"HTTPS_PROXY=http://<username>:<password>@<host>:<port>"

If you are looking to set a proxy on Linux, see here

over 4 years ago · Santiago Trujillo Relatório

0

The answer of Alexandre Mélard at question Cannot download Docker images behind a proxy works, here is the simplified version:

  1. Find out the systemd script or init.d script path of the docker service by running:service docker status or systemctl status docker, for example in Ubuntu16.04 it's at /lib/systemd/system/docker.service
  2. Edit the script for example sudo vim /lib/systemd/system/docker.service by adding the following in the [Service] section:

     Environment="HTTP_PROXY=http://<proxy_host>:<port>"
     Environment="HTTPS_PROXY=http://<proxy_host>:<port>"
     Environment="NO_PROXY=<no_proxy_host_or_ip>,<e.g.:172.10.10.10>"
    
  3. Reload and restart the daemon: sudo systemctl daemon-reload && sudo systemctl restart docker or sudo service docker restart
  4. Verify: docker info | grep -i proxy should show something like:

    HTTP Proxy: http://10.10.10.10:3128
    HTTPS Proxy: http://10.10.10.10:3128
    
  5. This adds the proxy for docker pull, which is the problem of the question. If for running or building docker a proxy is needed, either configure ~/.docker/config as the official docs explained, or change Dockerfile so there is proxy inside the container.
over 4 years ago · Santiago Trujillo Relatório

0

I had the same problem on a windows server and solved the problem by setting the environment variable HTTP_PROXY on powershell:

[Environment]::SetEnvironmentVariable("HTTP_PROXY", "http://username:password@proxy:port/", [EnvironmentVariableTarget]::Machine)

And then restarting docker:

Restart-Service docker

More information at Microsoft official proxy-configuration guide.

Note: The error returned when pulling image, with version 19.03.5, was connection refused.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda