VMware Modern Apps Community
nithinp
Contributor
Contributor
Jump to solution

How to set proxy to access internet on photon

Hi

I have successfully deployed photon OVA templated on vSphere 5.5 setup, when I am trying to install docker using the command "docker run -d -p 80:80 vmwarecna/nginx" its says unable to reach internet. Since my setup is behind a proxy server, I have tried to set proxy in a traditional linux method, however I am still not able to reach internet.

Can you help me to find a way to set proxy ?

SO far I have tried to setup proxy by running below commands.

#export http_proxy=http://foo:bar@server-ip:port/

#export https_proxy=http://foo:bar@server-ip:port/

I am using below link to install docker.

https://github.com/vmware/photon/wiki/Running-Project-Photon-on-vSphere

Reply
0 Kudos
1 Solution
7 Replies
AnthonyChow
Hot Shot
Hot Shot
Jump to solution

Try changing /etc/sysconfig/docker

There is a export http_proxy that you can uncomment.

Reply
0 Kudos
nithinp
Contributor
Contributor
Jump to solution

I do not see any file/directory by name docker under /etc/sysconfig --  this is what I see under sysconfig

pastedImage_1.png

Version of Photon

pastedImage_0.png

Reply
0 Kudos
AnthonyChow
Hot Shot
Hot Shot
Jump to solution

Did you have a chance to look at this link?

Control and configure Docker with systemd

"You can customize the Docker daemon options using override files as explained in the HTTP Proxy example below. The files located in /usr/lib/systemd/system or /lib/systemd/system contain the default options and should not be edited."

Hope this helps.

Reply
0 Kudos
nithinp
Contributor
Contributor
Jump to solution

Thank You So much, this helped me 🙂

Reply
0 Kudos
AnthonyChow
Hot Shot
Hot Shot
Jump to solution

Smiley Happy

Reply
0 Kudos
battybishop
Hot Shot
Hot Shot
Jump to solution

Thanks, this helped me too 🙂
Reply
0 Kudos