Fluency Administration
1. Account and Password Information
There are several accounts and applications used throughout the class that we need to maintain. The basic information follows below:
tintin
The most important account is tintin.cs.indiana.edu. This is the server on which the various applications run (Bamboo Jira, etc.), where the fluency website is, and where the SVN repository is. Currently, there is no login account for tintin; access can be configured for a particular account on the CS network through an SSH key. The following web page describes the process of setting up an SSH key:
http://www.cs.indiana.edu/Facilities/FAQ/Security/openssh.html
After setting up an SSH key, you need to contact the sys admins to allow you access to tintin. The quickest way to do this is to submit a ticket here:
https://soichelp.informatics.indiana.edu/request/
Once SSH access has been set up to tintin, you can access it by typing 'ssh kspace@tintin' on any departmental machine and then entering your CS login/passphrase information.
Applications
In addition, three of the tools used in the class need to be maintained or administered in some way through out the semester. These are Confluence (the wiki), Bamboo and Jira. The URLs for the tools' websites are included in the next section. There is a passwords.txt in the root user folder on tintin that lists the passwords for access of these websites. For all three, the administrator user is 'admin'. Important tasks that can be carried out in these tools are described below.
Important Websites
Course website: http://www.cs.indiana.edu/~rawlins/b490.html.
Make sure the course website is also accessible from http://www.cs.indiana.edu/classes/b629/. If the link there is out of date, you need to contact the sys admins to update the page.
Confluence (the class wiki): http://fluency.knownspace.org/confluence/dashboard.action
Bamboo: http://fluency.knownspace.org/bamboo/start.action
Jira: http://fluency.knownspace.org/jira/secure/Dashboard.jspa
2. Creating a New Fluency Build
The current Fluency build is FallAlpha2009. If another version of the code base needs to be created and checked into CVS, the following steps can be followed:
a. Copy the FallAlpha2009 directory and rename it to whatever you want the new project name to be, say 'NewAlpha2009'.
b. Delete all '.cvs' directories and subdirectories under NewAlpha2009.
c. Open the build.xml file at the root of NewAlpha2009. Change the project name at the very top of the build file, as well as the following property values to reflect the new project name and directory: webstart.location, dist.coverage.dir, jar.filename. You can also change all .jar filenames appropriately, simply do a search for '.jar' and rename as you go. Finally, towards the very end of the build file you'll need to change the following line according to the new jnlp name you specify in step d.
<copy file="${webstart.home}/fluency-fall09.jnlp" toDir="${webstart.location}" />
d. In webstart/, rename the jnlp file if necessary. Then, open it and change the code base property of the jnlp tag and '<jar href="fluency-fall09.jar" />' according to the new naming scheme. In case you want to be able to generate separate jars for each build, you will need to edit the .php files in wwwroot/fluency/webstart/fall2009 on tintin in the same way. For more details, see step 5 in this document.
e. Add NewAlpha2009 to CVS and Commit.
f. The tests and coverage files that get generated will now be placed in directories according to the property changes made in step c. The links (JUnit, Emma, Try Fluency!) on the main class wiki page will need to be changed accordingly. In addition, you should go to the 'Try previous builds from Fall 2009' link and add the version of fluency that used to be the current one.
3. Creating Assignment Builds Supporting Bamboo, Emma, Webstart, Etc.
a. Create a new project in Eclipse with an empty src directory. Name it appropriately.
b. Use one of the fall 2009 projects as a template. These instruction assume the template used is from CVSHEAD/fall2009/project6/Team1-a6-Lei-Dhanalaxmi-Yohanan-Chintan.
c. Copy the lib/ and webstart/ directories, and the build.xml file into the new project.
d. Rename all files under webstart/ according to the new project name, i.e. 'team1-a6' becomes something else.
e. Open build.xml and change the names and paths of all webstart related files according to the rename that you did in the previous step. The easiest way to do this is to do a search in the file for the current name, e.g. 'team1-a6' and start renaming from there. In addition, change the project name, the echo message in the 'noop' target, and the 'webstart.location', 'key.store' and 'dist.coverage.dir' properties. Finally, do another 'team1-a6' search to rename any remaining references to the old name in file references.
f. Open the .jnlp file in the webstart directory, and update any references to the old project with the new project name and paths. This includes changing the codebase and href properties of the jnlp tag, the title tag, the description tags, the href property of the jar tag under resources, and the main-class property of the application-desc tag.
g. Open the .mf file and change the Main-Class file to correctly reflect the main class of the new project.
h. Create a test source folder in the project and place a sample JUnit test class. Such a class can be found in each a6 project from Fall 2009. Notice that the build scripts depends on test classes ending with Test, Tester or TestCase. If they don't, they won't be recognized as tests by Bamboo.
4. Creating a New Bamboo Project
It is easy to create a new Bamboo build configuration using a build configuration from a previous semester as a template. Go to the Bamboo website, log in as administrator and go to 'Create Plan'. Enter a 'Project Name' and 'Project Key'. Follow the naming pattern estabilished in previous projects. For 'Project', select 'New Project', and check the 'Clone an existing build' box. Select the desired project to use as a template. Currently, the 'Project 6 ...' and 'Fluency - Fall 2009' Bamboo builds are all reliable and can be used as templates. From here on, simply go through all configuration tabs, and make sure that any paths are changed according to the new project's name and location. Other than that, all other options should stay the same.
5. Generating Dynamic Webstartable JARs for Fluency
Currently, we want to be able to generate a unique JAR file name after each fluency build. This is accomplished through the buildnumber ANT task at the very start of the 'build-webstart' target. Because of the dynamic JAR naming, in order to make the latest build webstartable, we use a PHP script instead of a straight JNLP file. The script is /fluency/webstart/fall2009/fluency_fall2009.php. If creating a new Fluency build, copy this file to a new directory appropriate for the new project name, rename it and edit the references to fall2009 in it to reflect the new project name.
This file simply looks at what JAR files have been generated so far in order to find the latest one, and then creates the JNLP contents appropriately.
6. Restarting Bamboo
If you try to go to the Bamboo website, but get a 503 Service Temporarily Unavailable error, you need to restart the Bamboo server. Follow the steps below:
1) SSH to kspace@tintin.cs.indiana.edu (You will need to set up an ssh key on tintin. See the instructions in section 1.)
2) cd local/bamboo (This is important because the shell script which starts it references everything relative to the pwd)
3) ./bamboo.sh restart