Plug-in for Atlassian Bamboo CI Server 4.2 with Plastic SCM

Wednesday, August 29, 2012 , 0 Comments

Bamboo is a continuous integration (CI) server that can be used to automate the release management for a software application, creating a continuous delivery pipeline. Plastic SCM has implemented a new Bamboo 4.2 plug-in.

A Bamboo plug-in is a single JAR containing code. This new plug-in automatically detects and builds child branches off of the main tracked branch. The child branches (AKA Bamboo plan branches) inherit the main plan configuration to perform the builds.

Bamboo installation guide

The new plugin uses new Bamboo API's that are not present in the previous version. In this page, we’ll talk about the process to install Bamboo 4.2.x.. Check the system requirements. The supported platforms for Bamboo 4.2.x and for the Plastic SCM plug-in are Microsoft Windows, Linux/Solaris, and MAC OS X.

Choose your Bamboo distribution. Install and perform setup for Bamboo distribution.

BBDD

In the installation process you should choose your BBDD. In a wizard installation you can choose BBDD by default. In a production environment, just in case Plastic SCM and Bamboo use the same SGBD you could choose MySQL and name BBDD.

Plastic SCM with:

  1. Suffix: db.conf <DatabaseSuffix>
  2. Prefix: <DatabasePrefix> db.conf

Configure Plastic SCM with Bamboo

Now, we are ready to configure Plastic SCM with Bamboo.

The Plastic SCM installation guide shows you the complete process in simple points:

  • In the download page you can get the JAR file.
  • Copy the Plastic SCM JAR file you downloaded to the <Bamboo installation directory>/webapp/WEB-INF/lib or <Bamboo installation directory>/atlassian-bamboo/WEB-INF/lib directory. By default:
  • Restart Bamboo service

At this point, Plastic SCM is available in the source Repository combo.

Bamboo as a service

Since Bamboo is running as a service, you want Plastic SCM to look for its configuration files in the installation directory rather than in the user profile directory. Copy your client.conf and plastic.workspaces files in the Plastic SCM client installation directory.

  • c:\Program Files\Plastic SCM\client on Microsoft Windows
  • /opt/PlasticSCM/client on Linux
  • /Applications/PlasticSCM/client on Mac OS X

Bamboo started as a service so we should put the client.conf file in the Plastic SCM client installation directory in order to allow the System user access to that file. Bamboo uses an environment variable, ${build_dir}. Really, it’s just a directory where Bamboo stores all workspaces, so that Plastic SCM workspaces are hidden to Bamboo.


Now configure the client running: plastic --configure. Follow the normal steps in the wizard to specify your server and credentials.

Conclusion

You are ready to use Plastic SCM in your Bamboo plans now. When you select the "Plastic SCM" option in the Source Repository section, you can specify the workspace selector. The default selector will use the "/main" branch on the default repository.


The Plastic SCM team uses "branch per task" pattern which can blend perfectly with a slightly modified CI process.

Show off our pictures on flickr. Enjoy it!


0 comentarios: