This day I finally made a decision to start posting some notes on computer related stuff and mainly about how I solved some minor issues with software. Several month ago I already picked statically generated sites and GitHub pages as a hosting (I don’t expect other people to read this, I just don’t want to forget anything of it :-), so such hosting is enough for my needs). So I found a post Setting up Github Pages written by David Winter and started following steps described there.
Unfortunately, I failed at the very first step with command:
gem install jekyll
And got this error message from gem
:
WARNING: Error fetching data: Errno::ECONNREFUSED: Connection refused - connect(2) (http://rubygems.org/latest_specs.4.8.gz)
I tried using wget
to download the file:
wget http://rubygems.org/latest_specs.4.8.gz
and it worked greatly. So the next thing to try was running some of gem
commands that work locally:
gem list --local gem list -l
Which are worked fine, while these commands:
gem list --remote gem list -r
failed just like gem install jekyll
. After searching on the Internet to find
out possible reason on an issue a note about possibly incorrect setup proxy was found (here). I
didn’t actually use any proxy, but since I was playing with privoxy some
time ago and remembered something about $HTTP_PROXY
environment variable I
decided to check contents of my ~/.bashrc
and ~/.profile
and found this line
in the ~/.profile
file:
export HTTP_PROXY="http://127.0.0.1:8118"
I don’t know why other software didn’t complain about not working proxy, it seems like it just tried to use the proxy and then silently switched to direct connection configuration.
Anyway, after removing that line from the ~/.profile
and running
unset HTTP_PROXY
command in the working terminal I was able to successfully install jekyll
gem.