You should set the proxy for apt via /etc/apt.conf or /etc/apt/apt.conf.d/ The line you need is: Acquire::HTTP::Proxy "http://.../";