On Wed, Jul 23, 2003 at 04:17:40PM +1000, Andrew Cowie wrote: > On Wed, 2003-07-23 at 15:17, Max Kalika wrote: > > I've ported over most of the Horde apps to use this eclass in my > > local tree as an exercise and let me tell you, installing (and > > upgrading) Horde is actually pleasant now. > Oh, yeah, I can see that. The app I have in mind is dotProject (also a > PHP web app) > > Web Application installations ARE a bit more complex than just `make > install` the program: > > a) installing PHP app (ok, this is relatively straight forward - you > just unpack tarball somewhere and ta-da, but one *does* need to know > where to put it) > "Where to put it" does have slightly broader implications. Under the > machine's default DocumentRoot seems a good idea, but there are many > instances where one wants to make a separate virtual host for the > installation, or, or.... > Certainly as a first approximation, "sub directory of machine default > DocRoot" seems a not bad place to start, but I'm curious what others > think we should practice as I can think of numerous objections to this. After the 1.4 release (maybe before, depending on how busy I am with work), there will be a migration of all web applications to install somewhere like /usr/share/webapp/${P} (maybe ${PF}) You will then be able to create instances of the package by having that /usr/share/webapp/${P} in PHP's include path, and all you do is have the configuration files in your instance directory, enabling you to have as many instances as you want, securely, with only one set of main files, even accross virtual hosts. Config files probably be in /etc/webapp/${P} which will be symlinked to from wherever you have the instance. This is to protect them, but I am not 100% if this will be needed with the instances. > b) ensure you've got all the dependencies. (Yuk). Easy with Gentoo. RDEPEND=... for most webapps. > c) configure application [not so optional, but in Gentoo you are > expected to do this on your own; also applies to:] see what the phpMyAdmin ebuild does for making this REALLY good. > d) install DB tables [optional, depends on which DB you're running, etc, > etc... could guess from USE flags, but who wants an app just madly > crashing around creating tables, especially when config may not be in > place and when, if an upgrade, tables all ready exist] Again, see the phpMyAdmin ebuild. > Is there a way that that can be automated too? I suspect not, without > going to something like linux-control-center or debconf or some similar > craziness] I don't know if you have played with zope-config, but expect something like that for the web application setup. -- Robin Hugh Johnson E-Mail : robbat2@orbis-terrarum.net Home Page : http://www.orbis-terrarum.net/?l=people.robbat2 ICQ# : 30269588 or 41961639 GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85