Install system - requirements
Update: an installer finally got into Drupal 5
Over the last few weeks, I have been attempting to simplify the deeper intricacies of installing, and maintaining a drupal system, while allowing for a more centralized/controlled method of providing database scripts for contributed modules.
A good example of the intended result would be quotes and menus in the contrib modules. The modules contain the neccesary SQL to create, and update the tables required for operaton/installation of the module directly within the .module code. This makes them incredibly userfriendly, and simple for even the greenest newbie to install a contributed module without needing to know anything about MySQL, PostgreSQL an ssh connection and yes , even phpmyadmin.
I have managed to develop the framework to such a point, that I have successfully installed the core system (with screenshots), with the desired database prefix, based on the absolute minimum amount of information required to install the system (ie: a successfull database connection, table selection and the optional prefix). I have managed to upgrade Drupal 4.3.0 systems to cvs head using the install system, and I have managed to install and update small demonstration modules for the API.
This has been discussed on the devel lists several times over the few months that I have been subscribed, and also used to penalize drupal whenever there is a review. The general consensus for a long time has been that it is either unneccesary , or that the current setup of .sql dump, and update.php is sufficient for our purposes. The real reason that drupal doesn't have a cleaner install , is that noone has put forward a clean , concise and internally consistent proposal for the functionality.
For the more technically inclined, I have detailed large parts of the api I have developed here (base install/update), and here (configuration/wizard system).
My requirements for an install system are probably not indicative of the actual user/developer base of drupal however. When I started this little project of mine, I simply wanted to fulfill the following:
- install drupal core system , for drupal core initially, but available to contrib modules too.
- integrated support for different RDBMS systems. I maintain the postgres port, and I would prefer to have a consistent interface with which to add postgres support to the core and / or contrib modules.
- database prefix installations without needing to modify the sql dump.
- a method to configure settings from user input, with full error checking.
- allow contributed modules access to the api , so that all database creation/update happen consistently.
- not encumber the modules themselves by including, and parsing the
- update the system, based on the changes made since the system was installed. This is directly analogous to the current update.php process, however in a more rigidly defined structure, and capable of updating not only the main system. This requires rudimentary version checking, which at this stage is done using a 'date' , as in update.php.
After this point, I feel the actual requirements for what the default system install script should do, are not too clear. There are quite a few dissenting opinions regarding this on the devel list, but I feel the input of as many people as possible could only help. The framework for developing all this is pretty much done, but nailing down the actual configuration and setup requirements need to be done.
What I would like to know, is how you think the drupal install should work. Several of the users on this site will have used other open source CMSes with install scripts (such as Xoops, and Xaraya and PostNuke). What can Drupal learn from these , and what would you like to see from the install system?
Over the next few days I will be trying to nail down as much of the code as possible, as I am still aiming for a Drupal 4.4.0 inclusion (with any luck, the next drupal will be a lot easier for newbies to use, it is already shaping up as one of our better release imho).
The current workflow , as I have described elsewhere, is the bare mimimum .. 1) ask for a valid database username and password, do not allow the user to continue until the connection has been made successfully. 2) ask the user for the site name and URL .. this is currently ignored, as I feel this is part of a bigger step somewhere. 3) install the database schema.