Configure proxy for APT
Create and edit the following file:
sudo nano /etc/apt/apt.conf.d/99proxy
Add the following configuration
Acquire::http::Proxy "http://USERNAME:PASSWORD@SERVER:PORT";
Acquire::https::Proxy "http://USERNAME:PASSWORD@SERVER:PORT";
example:
Acquire::http::proxy "http://lgn:pwd@192.168.1.254:8080/";
Acquire::https::proxy "http://lgn:pwd@192.168.1.254:8080/";
Save and exit.
References
https://askubuntu.com/questions/257290/configure-proxy-for-apt
https://stackoverflow.com/questions/25322280/how-can-i-configure-a-http-proxy-for-apt-get