2009/11/10

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.

2009/10/20

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.

2009/10/13

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:

2009/10/07

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.

2009/09/24

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.

2009/09/23

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.

2009/07/24

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:

2009/07/21

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.

2009/07/02

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.

2009/07/01

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.

2009/06/16

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.

2009/06/09

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.

2009/06/08

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.