Docker Community Forums

Share and learn in the Docker community.

Yum install behind a proxy inside a docker container


(Marwenb) #1

Hi all ,
I want to a execute a yum install inside a docker container but i’m using a proxy so i got this output:
"Couldn’t resolve proxy ‘XXXXXX’"
I add the export proxy in the bashrc file also i execute the proxy in the container prumpt but it still the same issue.

(Msreekanth) #2

Were you able to figure out?

I tried setting proxy using these 3 ways. But still couldnt get it working inside corporate network. At home with out proxy, I am able to get packages installed from yum.

  1. passing the build argument using --build-arg HTTP_PROXY=******: 80

  2. By using the ENV inside Docker File

  3. By setting the proxy in ~/.docker/config.json

Please help.