Monday 20 May 2013

Apt-get from the command line behind a proxy

I'm putting this on here more as just a reminder for myself as much as anything else. I've recently started putting more effort into developing my Linux knowledge and I've been setting up an Ubuntu server without a GUI. One of the first problems I found was that I couldn't update apt-get. It turns out that apt-get doesn't automatically see the system proxy settings but can be fixed simply with one command:

export http_proxy="http://username:Password@foo.bar:8080"

Many thanks to Cybernerd on EduGeek for this spark of genius!