Search This Blog

Tuesday, July 30, 2013

Automatic set proxy on boot on Linux

You can set the variable globally in /etc/profile or by creating a script for your variable in /etc/profile.d:

export http_proxy="http://\:@:"
export https_proxy="http://\:@:"

Use network proxy environment settings for "sudo" user on Linux

the trick is to add enviroment variables to sudoers config:
sudo nano /etc/sudoers
add these lines:
Defaults env_keep +="http_proxy"
Defaults env_keep +="https_proxy"
from ArchLinux wiki https://wiki.archlinux.org/index.php/Sudo#Environment_variables_.28Outdated.3F.29