Cabal installation package fails

I access via the Internet through a proxy server and configure environment variables accordingly. The problem is that whenever I try to install any package through cabal, it fails with

connect: does not exist (Connection Refused) error.

But if I run cabal update -v3, it will successfully establish a connection and receive update information.

$ cabal --version   
cabal-install version 1.20.0.2
using version 1.20.0.1 of the Cabal library

Edit: I am running Ubuntu 14.04 .

+4
source share
1 answer

Good. Problem resolved with command -Ec sudo.

sudo -E cabal install <package>

Although, I do not understand why I cabal updatecould work, but not cabal install.

+1
source

All Articles