Step 1. Convert SSH Keys to Putty format.
Note: You need to execute this step only once.
When rhc tools are installed, your SSH keys are created in the OpenSSH format. This format differs slightly from the PuTTY format. In this step, we'll import the OpenSSH key that you have created earlier and convert it to native PuTTY format.
If you have PuTTY and PuTTYgen already, continue; otherwise, download PuTTY and PuTTYgen from http://www.chiark.greenend.org.uk/~sgtatham/putty/.
Start PuTTYgen and select Conversions -> Import Key
By default, OpenSSH stores your keys in drive:\Documents and Settings\user\.ssh folder on WindowsXP, or in drive:\Users\user\.ssh folder on Windows 7. In the file selector, navigate to this folder and select id_rsa file that contains your private key.
You may see another file that is actually a public key id_rsa.pub -- Windows may misidentify it as a 'Microsoft Publisher' file. If you try to select id_rsa.pub, Puttygen errors that this file does not contain a private key.
Once imported, you will see the following imported information in Puttygen.
Then, click on Save private key and choose the same drive:\Documents and Settings\user\.ssh folder. The file name defaults to id_rsa.ppk.
You should now have three files in this folder: OpenSSH private key id_rsa, PuTTY private key id_rsa.ppk and public key id_rsa.pub.
We will use this key in the following sections when accessing your application securely.
Step 2. Determine username and host name.
The FAQ referenced above refers to the UUID and Gear Name. In PuTTY, this fields have to be separated.
You can find the UUID and gear name information in the OpenShift management console by selecting your application.
The string with the git repository contains the required information:
Step 3. Establish SSH connection using PuTTY.
Start PuTTY and paste Gear name as the Host Name as shown below:
Then, navigate to Connection->Data in the left panel and paste the complete UUID as the Auto-login username, as shown below. Since the UUID is quite long, it may not fully display.
Lastly, navigate to Connection->SSH->Auth and select the id_rsa.ppk as your Private key file for authentication, as shown below:
Finally, select Open to connect to your Application's gear.
Be careful with the shell access since you may accidentally damage your application.
One of the useful capabilities of SSH access is viewing your applications logs. To access logs, use the following commands. "demo3" here is my application's name.
> cd demo3/logs > ls > view error_log-20120607-000000-EST
To disconnect, type exit.