Topic: Ideas for simplifying installation

Topic type:

Walking through some ideas on how we can make installation friendlier.

Those that have installed Kete themselves from scratch, vs installing on a system that already has another Kete site running, understand that it involves a lot of steps to complete. To my mind, the amount of actions necessary for installation, and chances for things to inadvertently missed, is the biggest hurdle to using Kete. I have a few ideas about how this can be improved.

Required Software

The majority of the steps involved are actually installing other software that Kete requires. Things like the Zebra search engine and Ruby Enterprise Edition. These steps are ripe for being automated as they don't change frequently. Depending on the operating system that you are installing to, there is a good likelihood that there are existing packages in a package management system to install these pieces. In the past, because of this, many have suggested creating a Kete package for these operating systems that would call these other packages as dependencies (pre-installation steps). I have resisted this for reasons I'll talk about below.

However, creating a "Kete required software installer" package that sets the stage for hosting a Kete site makes sense.

Essentially this package would be a sort of meta package that describes Kete's required software, triggers installing pre-existing packaged software where possible, builds and installs anything that has to be installed from source, and finally reports back further configuration steps if necessary.

It wouldn't install the Kete source code itself and it wouldn't handled Kete's Ruby dependencies either.

A bit of background: the split between Ruby dependencies and "everything else"

Kete is a Ruby on Rails application and like other Ruby programs it makes use of the Ruby language's default software package management tool, RubyGems. Kete requires you to install a number of these "gems" to support its functionality. Gems are very easy to use, have a great community where the software it distributes evolves rapidly while maintaing a strong emphasis on quality. In fact, several pieces of functionality have been written for Kete and given back to be used by other Ruby applications through RubyGems. 

The RubyGems package manager is not tied to any particular operating system or Linux distribution. It is language specific parallel system and it tends to move at a much faster pace than built-in package managers.

For Kete to stay on top of what is going on with the Ruby community, we have chosen to do the following:

  • install everything that is not the Ruby language itself or a Ruby gem with the "local" package manager for the operating system where possible
  • for ease of compatibility through consistency, install our own version of the Ruby language with Ruby Enterprise Edition, that is separate from the operating system's included Ruby
  • install all other Ruby software with gems (or in Rails case, also Rails plugins)

We've done this for some time at Katipo and it works well. Eventually the Kete project will make use of a gem called Bundler that will make this even easier to manage.

Therefore, one reason I don't recommend a monolithic Kete package is because it would be difficult with this "split". Also, there is a better model.

A bit more background: installing many Kete sites on the same host

Some Kete sites are run on dedicated hosts where there is one Kete only, but the truth is that once you have installed one Kete site on a host server, it is much much easier to install your next Kete site onto that host because you only need to install's Kete source code, not re-install all of its required software.

Shared hosting, many Kete sites running on one host, is quite common at Katipo and at other hosting providers for this reason.

This is not unlike how Ruby on Rails itself is installed. With Ruby on Rails, you install the Rails gem (which in turn installs many other gems it depends on) and then use it to install one or many Rails applications on your host.

Unsurprisingly as Kete is a Ruby on Rails application, I propose that we follow this pattern.

Kete Ruby Gem

We should create a gem that does these things:

  1. installs any Ruby gems that Kete needs
  2. installs a command that main purpose is to install the Kete source code under the name that the user specifics
    • e.g. "kete_install my_app_name" creates a new Kete application under "my_app_name" directory
  3. the command, when run, also gives the user instructions on the final configuration steps for a new Kete site (Apache configuration, etc.)

Wrapping up

So the proposal is this:

  1. we create platform specific packages that install all of Kete's required software (that isn't a Ruby gem)
  2. we create a Kete installer Ruby gem that has the (reusable) ability to download and create a Kete application and installs Kete's gem dependencies in the process

Please comment below.

My plan is to do a proof of concept "Kete required software" package on the Homebrew system for Mac OS X soon and follow that up with first cut of Kete installer gem thereafter. Feel free to raise your hand to help out for other platforms or the gem.

Discuss This Topic

There are 0 comments in this discussion.

join this discussion