5 KiB
Executable file
Installing Ruby Fog Bindings for HP Cloud Services
Before you can begin working with the Ruby Fog bindings, you have to install them (of course!). This page provides you with the installation information for the following operating systems:
To install and use HP Cloud Ruby bindings for Fog, please install the latest release of Fog.
Ubuntu Installation
If you plan on using the Ruby Fog binding on Ubuntu, we recommend you use Ubuntu versions 12.04 or 12.10. The Ruby Fog bindings may work on other versions, but are not supported.
To install the Ruby Fog bindings on the Ubuntu operating system, follow these steps while logged in as the root user:
-
Install Ruby and Ruby-dev:
apt-get install ruby1.8 ruby-dev
-
Install RubyGems:
apt-get install rubygems
-
Install the dependent libraries:
apt-get install libxml2 libxml2-dev libxslt1-dev libxslt1.1 sgml-base xml-core
-
Install the RDoc Ruby source documenation generator package:
gem install rdoc
-
Install the Fog gem:
gem install fog
See the Connecting to the Service page for details on how to connect.
MacOS X Installation
Some Ruby packages require C/C++ compiler support. On the MacOS, if you haven't already installed XCode, we recommend that you install it to provide the needed C/C++ compiler for your system.
To install the Ruby Fog bindings on MacOS X, follow these steps while logged in as the root user:
-
Download and install Xcode. You can download the most recent version of XCode through the Mac App Store. If you want to install an earlier version of Xcode, go to the Apple Developer site and search for "Xcode". In the results list, select the version of Xcode that you want and install it. (Note that you need to be signed up as an "Apple Developer" to access the download. Sign-up is free.)
-
To make your installation process easier we recommend that you install Homebrew. Follow the instructions on the Homebrew page to install the package. After you have downloaded Homebrew, the CLI command to install it is:
homebrew install - ruby -e "$(curl -fsSkL raw.github.com/mxcl/homebrew/go)"
-
Add the Homebrew path to your $PATH environment variable. You can either do this via the CLI command line:
export PATH=:/usr/local/sbin:$PATH
(The default Homebrew installation location is the
/usr/local/sbin
directory.) Or you can add the Homebrew path (/usr/local/sbin
) to your $PATH environment variable in your local.profile
file. -
Install RVM on your system:
curl -L get.rvm.io | bash -s stable
Note: You can also install RVM using Jewelry Box, a RVM graphical user interface (GUI) for Mac OSX.
-
Install the packages required by RVM; the following command lists the required packages:
source ~/.rvm/scripts/rvm rvm requirements # install required packages
-
Install the required packages listed in Step 5:
brew install <packages>
Where
<packages>
are the packages that you need to install. -
Install the
libksba
library:brew install libksba
-
Install Ruby:
rvm user all rvm install ruby-1.9.2 --with-gcc=clang
-
Use the Ruby version and make it the default:
rvm use 1.9.2 --default
-
Install the Fog gem:
gem install fog
See the Connecting to the Service page for details on how to connect.
CentOS Installation
If you plan on using the Ruby Fog binding on CentOS, we recommend you use CentOS versions 6.2 or 6.3. The Ruby Fog bindings may work on other versions, but are not supported.
To install the Ruby Fog bindings on CentOS, follow these steps while logged in as the root user:
-
Install Ruby and Ruby Dev:
yum install -y ruby ruby-devel
-
Install Rubygems:
yum install -y rubygems
-
Install the dependent libraries:
yum install -y gcc make libxml2 libxml2-devel libxslt libxslt-devel
-
Install RDoc Ruby source documentation generator package:
gem install rdoc
-
Install the Fog gem:
gem install fog
See the Connecting to the Service page for details on how to connect.
Uninstalling
Its recommended that you uninstall a previous version prior to upgrading. To uninstall, execute the followin command while logged in as the root user:
gem uninstall fog