Configuring IBM WebSphere Application Developer or Eclipse to work with CVS over SSH

17 July 2004 »

This walk-through will help you set up your Eclipse-based IDE to connect to a CVS repository server over SSH.

This particular example assumes IBM WebSphere Application Developer 5.1.1 on Windows XP Professional and a Solaris 9 server running the Community Software Package distribution of CVS 1.11.16.

DISCLAIMER: Though I work for IBM, the instructions on this site solely reflect my personal experience configuring IBM software and do not necessarily represent the views, positions, strategies or opinions of IBM, IBM management, or IBM support.

UPDATE: 19 July 2005. Many of the workstation steps are not necessary for Eclipse version 3 or Rational Application Developer 6. You may be able to simply choose extssh as your connection method and specify Plink as your SSH tool. I will have more details in the future. In the case of Eclipse 3.1 on Mac OS X, ssh will already be in your PATH and you should be able to connect directly with the extssh method.

UPDATE: 17 November 2005. It has come to my attention that the CVS version patch which was linked to no longer exists on that server. I have checked my own plugins directory and posted a zipped version here. This copy has been tested and works.


  1. A Unix-like server running an SSH2 daemon to be used as a CVS repository location.
  2. A Windows workstation running IBM WebSphere Application Developer or Eclipse.
  3. On the workstation, have PuTTY, Pageant, Plink, and PuTTYgen.

Configuring the CVS server

  1. Download a copy of CVS.
    In my case I downloaded the CSW package which installed at
    /opt/csw/bin/cvs with the command pkg-get -i cvs
  2. Prepare the repository location in the recommended location.
    mkdir /var/lib/cvsroot
  3. Create the CVS users group (cvsgroup).
    groupadd cvsgroup
  4. Create the CVS user id (cvsuser).
    useradd -d /export/home/cvsuser -m -g cvsgroup cvsuser
  5. Change the new user’s password as root.
    passwd cvsuser
  6. Modify existing users to add them to the CVS users group.
    usermod -G cvsgroup [username]
  7. Change group ownership of the repository.
    chgrp cvsgroup /var/lib/cvsroot
  8. Set group ownership bit for files created in the repository.
    chmod g+srwx /var/lib/cvsroot
  9. Initialize the repository.
    cvs -d /var/lib/cvsroot init
  10. Change owner user of the initialized repository.
    chown -R cvsuser /var/lib/cvsroot
  11. Uncomment the lock directory value (LockDir=/var/lock/cvs)
    in the configuration file, /var/lib/cvsroot/CVSROOT/config
  12. Create the lock directory and set its permissions if it doesn’t already exist.
    mkdir /var/lock/cvs
    chmod 777 /var/lock/cvs

Initializing a project from a home directory on the server

  1. Upload existing assets to a temporary directory, such as ~/tmp
  2. From the root directory of the uploaded assets [~/tmp/projectname], run an import for the project. Delete the project from the ~/tmp directory afterwards.
    cvs -d /var/lib/cvsroot import [project] [vendor] [release]
  3. Set an environment variable for CVSROOT for all subsequent CVS activity [assuming bash].
    export CVSROOT
  4. Create a sandbox in your home directory
    mkdir ~/cvs
  5. From within the sandbox check out the project you imported.
    cvs checkout [project]
  6. Run updates or commits for each time you wish to update your sandbox or commit to the repository.
    cvs update
    cvs commit

Connect via SSH to the CVS server from the workstation

  1. Generate a public and private key using PuTTYgen.
  2. Save the private key locally.
    I saved it as key.ppk in my PuTTY directory
  3. Upload the public key to the server.
    I copied the public key and pasted it into a vi window on one line in ~/.ssh/authorized_keys
  4. Load Pageant, add the private key.
    Click Add Key and get the .ppk file
  5. Configure Plink to use the private key.
    Via the Command Prompt, fire up plink with the following command:
    plink user@host.tld -i key.ppk
  6. Connect with Plink to the server to test.
    You should now be on your CVS machine’s command line

Connecting to the repository from Eclipse or WSAD

  1. Before starting WSAD 5.1.1 or Eclipse 2.1.1, you’ll need to apply a CVS version patch to your plugins folder. Download the ZIP file and extract it to C:\Program Files\IBM\WebSphere Studio\Application Developer\v5.1.1\eclipse\plugins
  2. Set up the Team environment parameters.
    Open Window > Preferences then
    Team > CVS > Ext Connection Method
    CVS_RSH should be the path to plink.exe
    Parameters should be {user}@{host}
    CVS_SERVER should be the path to the server version of CVS. In some cases it can just be cvs. In my case I gave it the full path /opt/csw/bin/cvs
    Click OK
  3. Create a repository location.
    Window > Open Perspective > Other
    Choose CVS Repository Exploring
    Right click in the CVS Repositories pane and choose New > Repository Location
    Enter the Host, Repository path, User, and Connection type. Password MUST BE BLANK host.tld, /var/lib/cvsroot, user, ext Use default port
    A Plink window may quickly show up as the connection is made
    You should be set with the connection now
  4. Check out as project.
    From within the CVS Repositories pane, pick your repository, then choose HEAD and highlight your project.
    Click Check Out As Project and you will now have the project.
  5. Note that everytime you restart your computer, you will need to load Pageant and add your local key for Plink to work from within WSAD or Eclipse.



Leave a Reply