How to Integrate InstallBuilder with Apache Ant and Apache Maven

Apache Ant and Apache Maven are two of the most popular tools for building projects. This article explains how to integrate InstallBuilder with these two tools.

If you use Apache Ant for building your projects, you can include the following section for building your binary installer.


InstallBuilder Action Lists

Creating an installer is not as straightforward as most people think. This is especially the case for more sophisticated configurations, such as when you need to execute different platform-specific actions at different stages of the installation process. You may need to check a registry value, create a configuration file, execute a particular command, make substitutions in text files or even connect to an external server via a HTTP POST request. BitRock InstallBuilder includes a number of useful built-in actions to facilitate adding complex functionality to your installer. Actions can be accessed by editing the XML project file directly or in the 'Advanced' section of the InstallBuilder GUI.

InstallBuilder actions are organized in what are called action lists, which are executed at specific points of the installation process. It is important to understand how and when each action must be performed, what differences exist between action lists inside components and within the primary installer, how the installer will behave when you run it in different installation modes (GUI, text, or unattended) and what happens when you generate rpm or deb packages.


Unattended Mode

As you may know, installers generated with InstallBuilder provide different execution modes using the command line option "--mode". The mode "unattended" is particularly useful when we need to incorporate installations into an automated process. With this mode, the installer will not prompt the user for any information and will instead take the default settings configured for each of the parameters. That way, it is possible to incorporate the installer execution into scripts since no input is required from the user during the installation.

Note that you are not forced to use only the default values when running the installer in this mode. You can also define the values through command line switches which are generated for each parameter definition inside the InstallBuilder project. If we want to use specific values, we should run the installation as follows:


InstallBuilder 6.2.4 Now Available

We just released version 6.2.4 of InstallBuilder our crossplatform installation and automatic update tool. The new release includes several enhancements, such as an improved builder tool on Mac OS X x86 and unattended install support for the autoupdate mechanism. The addition of unattended mode in the automatic update tool means that updates can be applied silently without user interaction. A complete list of improvements can be viewed in InstallBuilder's changelog.


Bundle Tomcat in Your BitRock InstallBuilder installer

If you develop a Java Web Application, you may want to create an installer and redistribute Tomcat together with your software. This allows your users to avoid the time-consuming process of installing and configuring Tomcat in order to use your software and guarantees that the optimal version is used. In this article, we explain how to bundle Tomcat into a BitRock installer. We also provide the code so you can start with that and create an installer that not only installs your software but also configures the Tomcat server according to your requirements.


LinuxCon and JEI

BitRock will be attending LinuxCon in Portland and the JEI Startup event in Zaragoza (Spain). Let us know if you are around and would like to chat with us.


Managing Bundled Files

In this entry we are going to discuss how to manage files bundled within an installer.

It is common to have a separate tool or program that must be bundled with and run from the installer, but before the file copying part of the installation process has completed. A common example would be a license validation program. Typically, all files bundled within an installer are unpacked and then any tools would be run. In the case of a license validator, that is less than ideal because the user may end up waiting for the files to be unpacked only to find that the license is not valid. The user would then have to wait for the installation to be rolled back.

InstallBuilder provides you with actions to deal with these situations. The most important are <unpackFile> and <unpackDirectory>. Let's assume we are in the situation detailed above. A typical project XML file would look something like:


How to use Rules with InstallBuilder

The installation of your application does not have to be a rigid, linear sequence of actions. For example, maybe you need to copy certain files only if the target platform is Mac or Linux, but not if it is Windows. Or you may want to modify or add some content to a file, but only if it is needed (you don't want to duplicate configuration settings). Here's another example of common functionality: You may want to discard or accept user input depending on whether it meets certain criteria.

Rules in InstallBuilder allow you to determine when to perform certain actions depending on the circumstances, variables and user inputs that are involved in the installation. It allows you to set conditions related to an action or an action group at any step of the installation, and they will be performed only if the condition is met. You can set not only one, but a set of multiple conditions that can be evaluated with an AND/OR group logic statement.

This article will explain how to implement conditional rules in your actions, how to select the appropriate rule for each case, and how this can help you to optimize your project and avoid duplicating code.


How to Use the AutoUpdater in InstallBuilder

In version 6.0 of InstallBuilder, we started shipping a new tool called AutoUpdater . This tool allows you to enable users to check for, download and apply updates for your software on their machines, getting the necessary files through HTTP or FTP. Although the Autoupdater is not yet available through the InstallBuilder GUI, it is very simple to configure.

How Does it Work?

There is a binary file which will poll the server to get information about the software versions available. The behavior of this binary is:
  • Read the INI file that contains information about where to contact the server and which version is currently installed (which should be delivered together with the binary)

  • Get the XML file from the server, which contains available versions for each platform.

  • If there's a newer version available (checking that the version ID received is higher than the current one stored in INI file), download and install it or notify the user (return code = 0) if it is run in unattended mode.
This binary may be customized to fit your needs using the command line tool 'customize' which is available in the AutoUpdater directory after performing InstallBuilder installation. The binary may be generated for several platforms: windows, linux or linux-x64; and an XML file will be used to indicate the tool how should the updater be customized.


How to Add Components and Make them Optional

BitRock InstallBuilder allows you to create cross platform installers that make it easy for end users to install your software. Though users are often presented with a simple 5-click process, the software bundled inside and its configuration are typically very complex and difficult to set up manually. Examples of this are posted on BitNami.org, where stacks like Redmine, Alfresco or KnowledgeTree, which are fairly complex to install manually, can be installed in minutes thanks to installers that automate the process.

All of the applications available via BitNami have many different dependencies, such as: libraries, databases, web servers, programming languages, run-times, etc. Apart from that, each of them has to be configured a certain way and then all of the pieces need to be integrated to work together. The installation process gets even more complicated if you want to make those 'modules' optional and allow the end user choose which ones should be installed and how they should be configured. BitRock InstallBuilder's components make the task easier.

What is a Component?

You can think of a component as a 'black box' you use to simplify the way you build the installer. It is kind of a partial installer inside the primary installer that only applies to a subset of the software you are packaging (such as Apache, MySQL, etc). This makes it very easy to re-use pieces of your installer and add and remove them as necessary. You can bundle files within components and add rules, scripts, actions, variables or parameter pages (which are used to ask the user how they want to configure that piece of software). Various components are then bundled inside the primary installer to present end users with a complete package. If you are familiar with DRY (Do not Repeat Yourself) or KISS (Keep It Simple Stupid) terms, then InstallBuilder components will surely make you happy.


How To Integrate Bitrock InstallBuilder with Eclipse

Did you know that it is possible to integrate InstallBuilder into your development environment?

You may already be familiar with the advanced GUI builder that was added in InstallBuilder 6. You can access most InstallBuilder features from the GUI, so you can develop complex installers without writing a line of code. However, there are situations in which that is not the ideal way to work with InstallBuilder. In addition to the GUI builder, you can work directly with the XML project file or interact with the tool using the command line interface. Both the XML project file and the command line builder interface turn InstallBuilder into a powerful development tool that can be integrated into your development environment.

There are a variety of Integrated Development Environments (IDEs) that support functions such as source code editing, compilation, automation and version control. You can also integrate the packaging functionality that BitRock InstallBuilder provides because most IDEs can be configured to use external tools.

In this article, we'll explain how to configure Eclipse to package your software with InstallBuilder. The configuration with other IDEs would be similar to this. This article is focused only on the basics - more complex configuration can be done to further customize your environment.


Great Week at JavaOne

We had a great week last week at JavaOne in San Francisco. It was great to meet a number of InstallBuilder customers in person. We also had an opportunity to learn about several cool new startups, including JRapid, which has developed a tool that speeds up AJAX application development, ScrumNinja, which offers a slick web app for managing Scrum, Micello, which has a cool indoor location-based-service on mobile devices and AgileIT, which makes it easy to add web services to your application.

I also gave a lightning talk on how BitRock worked with Logical Awesome to develop an on-site version of GitHub that is easy to install. The video should be posted soon and I'll be sure to provide a link once it is available.

As promised, we raffled off an EeePC, which was won by Frank from New York. Congratulations, Frank!

GitHub On-Premise Version Now Available

Last week, we announced the release of a customer's new product, GitHub:Firewall Install. Congratulations to our friends at Logical Awesome, the makers of Github, for the very successful launch of their on-premise edition!

If you're not already familiar with it, GitHub is a wildly popular web application for social coding, with over 80,000 developers already using the site. Built on top of the Git distributed version control system, it makes it easy for distributed teams to collaborate on software development projects.

Until now, GitHub was only available as a service, which made it inaccessible to companies that will not allow their code to be hosted outside of the corporate firewall for security reasons. After seeing increasing demand for an on-site version of their product, the Logical Awesome team approached BitRock to package the new version, GitHub:FI, for easy installation at customer sites.

BitRock developed a completely self-contained installer for GitHub:FI that enables new users to get up and running in just a few mouse clicks. The installer contains all of the software required to run GitHub: Ruby on Rails, JRuby, Solr, Java, Python, Perl, Git, Pygments, OpenSSL and over 30 additional components. It completely automates the installation and configuration process, so no manual setup steps are required. Logical Awesome is also taking advantage of the BitRock Network Service to better inform product development and support.

Want BitRock to make your software that easy to install?

Whether your software is built on PHP, Rails, Java, Perl or Python, we can deliver a complete package that enables even non-technical end users to have it up and running in minutes on Windows, Linux, OS X or Solaris. To learn more, contact our sales team.


How to Create Custom Pages with InstallBuilder

This week, we are kicking off a weekly series of 'how-to' posts for InstallBuilder, our crossplatform installation tool. Each how-to will include detailed instructions, as well as downloadable XML examples and (in most cases) a video demonstrating the process. In this first installment, we're going to cover how to create custom pages. InstallBuilder allows you to create multiple parameter pages: stringParameter, choiceParameter, booleanParameter... But what if you want a more customized page? Here is where parameterGroups come into play. parameterGroups allow you to define a list of parameters to be displayed in the same page and how to display them. This tutorial will be divided in 3 steps. First, we will design the page schema. In the second step, we will apply validations to fields. In the last step, we will perform actions based upon the user input.


BitRock Presenting at WhyFLOSS Madrid

In addition to JavaOne, BitRock founder and CTO Daniel Lopez Ridruejo will be giving a talk on BitNami at WhyFLOSS Madrid, a Spanish conference on open source software. If you're not familiar with it, the BitNami project provides popular web applications such as DokuWiki, Drupal, Joomla! and Wordpress in self-contained, easy to install packages. With BitNami, even non-technical users can get BitNami application stacks up and running on Windows, Linux, OS X or Solaris in just a few clicks. BitNami also includes several development stacks for Rails, WAMP, JRuby and more.

The WhyFLOSS event is being held in Madrid on May 21st and registration is free, although all of the talks will be in Spanish.


BitRock Selected Finalist of Spanish 2009 Internet Award

BitRock has been elected as a finalist of the 2009 Internet Awards in the category of best company. This nomination recognizes our work on BitNami and how it enables users of different backgrounds to quickly have up and running blogs, wikis and other web based programs. You can find more information at Dia de Internet website


Get $100 Off Your JavaOne Pass

BitRock will be exhibiting and demoing InstallBuilder, our cross platform installer development tool, at JavaOne, and you’re invited! If you’re not familiar with JavaOne, it is one of the leading events for Java developers. Held June 2-5 at the Moscone Center in San Francisco, it offers attendees an opportunity to hear from industry leaders and other technology experts – those programming directly in Java(TM) technology and those looking at it from new perspectives including scripting, RIA, open source and more. A wide range of sessions give developers a chance to get hands-on experience with Java and related technologies.

To sign up and get $100 off of your full conference pass, visit: cplan.com/javaone2009/externalregistration/reg.html and enter the code EXHBCEK5.

If you do attend the conference, be sure to drop by the BitRock kiosk to enter our drawing for a very cool prize!

PostBooks Open Source ERP Now Installs in Minutes

We're proud to announce xTuple, developer of PostBooks open source ERP, as a new BitRock customer! xTuple approached BitRock to help make PostBooks, its award-winning open source ERP, accounting, CRM and reporting software, easy to install.

The new BitRock Custom Stacks for PostBooks are self-contained installers that fully automate the installation and configuration process for PostBooks ERP, making it easy for even non-technical people to take the freely-available software for a spin.

To download PostBooks or sign up for a demo of the Standard or Manufacturing editions, visit xTuple.com.

In addition to the new easy to use installers (known as Custom Stacks), xTuple is also leveraging BitRock's Network Service to better service its large and growing user base. The Network Service enables xTuple to communicate new releases and other important messages to users while getting better visibility into how PostBooks is being deployed to improve product development and support.


New InstallBuilder Demo Video Up

Thanks to Yago, we have just posted a new demo video for InstallBuilder, our cross platform installer tool. The video shows how to build an installer for Pengupop, a networked multiplayer puzzle game released under the GPL. It's about 8 minutes long and will give you an idea of how InstallBuilder makes it easy to build a cross platform installer for your software.

Please take a look at the video and let us know what you think!

Nice work, Yago!


InstallBuilder 6.0 Now Available

We just released version 6.0 of InstallBuilder, and we are very excited about the improvements it includes. First, we have greatly expanded the GUI development environment, so you can now access all of InstallBuilder's functionality in a few mouse clicks. This makes building cross platform installers faster and easier than ever before. Here's just a taste of what you will find in the enhanced GUI:

We have also added another feature that sets InstallBuilder apart from other cross platform installation tools: automatic update functionality. So, you can now use InstallBuilder not only to package your software, but to deliver updates to it once installed. The automatic update tool currently supports Windows and Linux, with OS X support to be added shortly. It is included with InstallBuilder at no additional cost, so everyone with an active maintenance contract can take advantage of this new functionality.

In addition to the above improvements, support for right to left languages has been implemented. InstallBuilder 6.0 now supports Arabic, with more right to left languages to come. We want to thank our customers and in particular Mohammed El Mehdi for their help implementing this feature . If you are interested in a language not currently supported by InstallBuilder, please let us know by contacting support at bitrock .com

In connection with the new InstallBuilder release, we have created a new website just for InstallBuilder-related information, which simplifies navigation and makes it easier to access InstallBuilder information. You can click through to the site from bitrock.com, or visit it directly at installbuilder.bitrock.com.

To take the latest InstallBuilder release for a spin, download it and let us know what you think.


InstallBuilder 6 Preview

We have been working on an improved GUI for our builder tool as part of our plans for InstallBuilder 6. You can download a technical preview. The final version will include AutoUpdate functionality as well.