Friday, May 25, 2012

Get started on cloudfoundry.me


How to Install Ruby and RubyGems

http://docs.cloudfoundry.com/frameworks/ruby/installing-ruby.html#windows

Windows

Download and install Ruby Installer for Windows. The installer already includes RubyGems.

Be sure you use the Ruby-enabled command prompt window when you later install and use vmc. You access this command prompt from the Windows Start menu (All Programs > Ruby > Start Command Prompt with Ruby).

Finally, update RubyGems from the Ruby Command Prompt:

prompt> gem update --system

ruby 1.9.3p194 (2012-04-20) [i386-mingw32]

C:\Users\Thai Hau>gem update --system
Updating rubygems-update
Fetching: rubygems-update-1.8.24.gem (100%)
Successfully installed rubygems-update-1.8.24
Installing RubyGems 1.8.24
RubyGems 1.8.24 installed

== 1.8.24 / 2012-04-27

* 1 bug fix:

  * Install the .pem files properly. Fixes #320
  * Remove OpenSSL dependency from the http code path


-------------------------------------------------------------

RubyGems installed the following executables:
        D:/Ruby193/bin/gem

RubyGems system software updated

Installing vmc: Procedure
http://docs.cloudfoundry.com/tools/vmc/installing-vmc.html#installing-vmc-procedure

On Windows, open a command prompt in which Ruby is enabled and execute the following:

prompt> gem install vmc
Execute the vmc target command to specify the Cloud Foundry target to which you will deploy your applications:

To deploy on the PaaS Cloud Foundry, specify api.cloudfoundry.com
To deploy on your local Micro Cloud Foundry, specify api..cloudfoundry.me, where appname is the domain you registered for your application at the Micro Cloud Foundry Web site. See Installing Micro Cloud Foundry.
The following command targets the PaaS Cloud Foundry:

prompt$ vmc target api.cloudfoundry.com
To determine your current target, execute the `vmc target` command without any parameters:
prompt$ vmc target
Login using the user credentials you received via email after you registered with Cloud Foudnry. Your username is typically your email address.
prompt$ vmc login
Ensure you have successfully logged in by retrieving information about your account:
prompt$ vmc info
Change your password:
prompt$ vmc passwd
View the full list of VMC commands, along with their parameters and a brief description, by executing the vmc help command:
prompt$ vmc help
You have now successfully installed vmc and run a few basic commands.

Sunday, May 20, 2012

How can git be installed on CENTOS 5.5?




From source? From the repos? The easiest way is to use the repos: sudo yum install git should do it.
If you want to install from source, you can try these instructions. If you have yum-utils installed it's actually easier than that, too**:
sudo yum build-dep git
wget wget http://kernel.org/pub/software/scm/git/.tar.gz
tar -xvjf .tar.gz
cd 
make (possibly a ./configure before this)
sudo make install
**Substitute the portions enclosed in <> with the paths you need. Exact procedure may vary slightly as I have not compiled git from source, personally (there may be a configure script, for example). If you have no idea what I'm talking about, then you may want to just install from the repo as per my first suggestion.




[root@www local]# sudo yum install git
Loaded plugins: fastestmirror, priorities
Determining fastest mirrors
 * base: mirrors.serveraxis.net
 * extras: mirror.steadfast.net
 * jpackage-generic: sunsite.informatik.rwth-aachen.de
 * jpackage-generic-updates: sunsite.informatik.rwth-aachen.de
 * rpmforge: mirror.us.leaseweb.net
 * updates: mirror.wiredtree.com
addons                                                   | 1.9 kB     00:00
addons/primary_db                                        | 1.1 kB     00:00
base                                                     | 1.1 kB     00:00
base/primary                                             | 1.2 MB     00:00
base                                                                  3591/3591
extras                                                   | 2.1 kB     00:00
extras/primary_db                                        | 177 kB     00:00
jpackage-generic                                         | 2.3 kB     00:00
jpackage-generic/primary_db                              | 1.0 MB     00:01
jpackage-generic-updates                                 | 2.3 kB     00:00
jpackage-generic-updates/primary_db                      |  12 kB     00:00
rpmforge                                                 | 1.9 kB     00:00
rpmforge/primary_db                                      | 6.8 MB     00:04
updates                                                  | 1.9 kB     00:00
updates/primary_db                                       | 376 kB     00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
--> Processing Dependency: git = 1.7.6.1-1.el5.rf for package: git-daemon
--> Processing Dependency: git = 1.7.6.1-1.el5.rf for package: perl-Git
---> Package git.x86_64 0:1.7.10.1-1.el5.rf set to be updated
--> Running transaction check
---> Package git-daemon.x86_64 0:1.7.10.1-1.el5.rf set to be updated
---> Package perl-Git.x86_64 0:1.7.10.1-1.el5.rf set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package           Arch          Version                  Repository       Size
================================================================================
Updating:
 git               x86_64        1.7.10.1-1.el5.rf        rpmforge        8.0 M
Updating for dependencies:
 git-daemon        x86_64        1.7.10.1-1.el5.rf        rpmforge        317 k
 perl-Git          x86_64        1.7.10.1-1.el5.rf        rpmforge         28 k

Transaction Summary
================================================================================
Install       0 Package(s)
Upgrade       3 Package(s)

Total download size: 8.3 M
Is this ok [y/N]: y
Downloading Packages:
(1/3): perl-Git-1.7.10.1-1.el5.rf.x86_64.rpm             |  28 kB     00:00
(2/3): git-daemon-1.7.10.1-1.el5.rf.x86_64.rpm           | 317 kB     00:00
(3/3): git-1.7.10.1-1.el5.rf.x86_64.rpm                  | 8.0 MB     00:00
--------------------------------------------------------------------------------
Total                                           6.4 MB/s | 8.3 MB     00:01
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Updating       : git                                                      1/6
  Updating       : perl-Git                                                 2/6
  Updating       : git-daemon                                               3/6
  Cleanup        : git-daemon                                               4/6
  Cleanup        : perl-Git                                                 5/6
  Cleanup        : git                                                      6/6

Updated:
  git.x86_64 0:1.7.10.1-1.el5.rf

Dependency Updated:
  git-daemon.x86_64 0:1.7.10.1-1.el5.rf   perl-Git.x86_64 0:1.7.10.1-1.el5.rf

Complete!