'sudo gem install ...' behind a proxy
sudo visudo -f /etc/sudoers
It turns out that you need to do some tweaking if you want sudo to carry your proxy environment across from the current user. To do this, run sudo visudo and add the env_keep line below:
Defaults envkeep += "httpproxy httpsproxy ftpproxy"
$ sudo env | grep httpproxy
httpproxy=http://username:password@192.168.0.1:80/
http://jacob.stanley.io/2010/10/27/sudo-gem-install-behind-a-proxy/
Written by Matias
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Linux
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#