Creating and Deploying a smartsite-test.ucdavis.edu Release

Smartsite-Test deployment of new rSmart CLE tag

  1. Bring down new rSmart base source
    cd /src/cle
    svn co https://svn.rsmart.com/svn/customizations/ucd/tags/2.8.7.4-ea1 rSmart-CLE-2.8.7.4-ea1-ucdtest
    
  2. Fix CAS
    cd /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/config/sakai-login-tool
    vi rsmart.properties
    
    change the "cas.client.serviceParam" property to:
     cas.client.serviceParam=https://smartsite-test.ucdavis.edu/xsl-portal/login 
  3. Install/Fix mvn.sh
    cp /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/config/mvn.sh /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/cle
    vi /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/cle/mvn.sh
    
    Verify skin_home setting:
    skin_home=/src/cle/ucdtest-src-local/reference/library/src/webapp/skin
  4. Maven tweak
    cd /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/config
    mkdir maven_profiles
    cd maven_profiles
    ln -s ../osp-* ../rsmart* ../sakai* ../samigo/ ../upgrade/ .
    
  5. Copy over GB2 patches dir: Note the copy statement bellow gets the patches directory from the previous version
    cd /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/cle
    cp -R /src/cle/<previous version>/cle/patches .
    
    This concludes the first method of setting up the code for rSmart.

The next method is mainly meant for when something small, at least small in terms of code size and top level directories changes. The example used is for GB2, but the basic methodology can be used on other stuff .

Here's the basic method:

  1. Go to the directory where gradebook2 is located
    cd /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/cle/
    
  2. Backup old gradebook2 directory
    mv gradebook2 gradebook2-<today's data>
    
  3. Checkout the new gradebook2 tag
    svn co https://source.sakaiproject.org/contrib/gradebook2/tags/<tag name> gradebook2
    
  4. Apply patch that changes the maven pom.xml version
    cd gradebook2
    patch -p0 < ../patches/pom.patch
    svn diff
    
  5. For now, we need to apply a GRBK-616 patch. For more details, please see UPGRADE-LOG.txt
    patch -p0 < upgrade/gradebook2/GRBK-616.patch
    svn diff
    
    At this point the code should be able to be built.

Deployment

Now it is time to deploy the code. To do this you need two shells on acdc, one with the ucddev user and the other one as root.

Please be extremely careful doing anything as root and make sure you only run the one command you need to as root. Do not run the build as root.

As ucddev:

  1. Shutdown Sakai
    /home/ucdtest/cle/tomcat/bin/shutdown.sh
    
    Now until the java process is dead, do:
    ps -ef | grep tomcat | grep ucdtest
    
    At some point you are going to get impatient and want to kill the process. Please try to wait at least 30 seconds. When you kill it, do:
    kill -9 <procid>
    

    As its possible that this server may be running other java processes, do NOT killall -9 java or as such. Do a kill -9 on a proc id. The person running the extraneous java process will thank you for your discretion.

  2. Cleanup Tomcat directory.
    You will:
    export CATALINA_STAGING=/home/ucdtest/cle/tomcat
    ~/bin/tomcatclean.sh
    
  3. Build/Deploy sakai
    cd /src/cle/rSmart-CLE-2.8.7.4-ea1-ucdtest/cle/
    ./mvn.sh tomcat install sakai:deploy -Psakai2.8 -Dgb2.ui.version=<tag name>
    
  4. Get setup to launch:
    cd ~/cle/tomcat/logs/
    mv catalina.out catalina.out.predeploy
    touch catalina.out
    tail -f catalina.out
    

As root

Do not do this until you have completed the Build/Deploy step.

  1. Start Sakai
    /etc/init.d/cle_ucdtest start
    

As ucddev

Now all you do is watch the catalina.out for messages.

Post Deployment

At this point, you will want to log in, check to make sure things work. Remember to set the MOTD to reflect what is done, ie a new GB2 tag, or a new CLE base revision. The last step is to send mail to all interested parties that the node is back up.