Revision 7238 (by elias, 2006/04/22 21:11:06) renamed trunk->allegrowww, i guess that's all we need
=====================================
SourceForge cron script update_web.sh
=====================================

This is a small document for SourceForge administrators reviewing
the crontab entry used to update the Allegro web page.


Contents:
  1. `Purpose of the script`_
  2. `Rebuilding a file not under CVS control`_
  3. `Updating the whole website`_
  4. `Contact`_
  5. `Current user running this script`_


Purpose of the script
=====================

The script ``update_web.sh`` is stored in the ``allegrowww`` module
just like the rest of the web page source. The purpose of the script
is to:

 * Update a file not under CVS control with the contents of a directory.
 * Run a more complex website update script.
 * chmod/chown generated files to be .alleg and group writable.

The script doesn't implement locking, but the python scripts called
from it do. Even though the scripts are serialised, there are no
internal dependencies between them, so running ``n`` instances of
``update_web.sh`` shouldn't cause harm.

The web doesn't change frequently, we don't expect it to run more than
once a day.


Rebuilding a file not under CVS control
=======================================

The script ``scripts/sourceforge/update_cvs_snapshots.py`` has the
task of reading available files in a directory and generating a small
HTML-like file under ``src/sourceforge_autogenerated_snapshots``. It
also tries to remove older files if there are more than 10. The
script is very simple and doesn't do anything else, so it runs fast.


Updating the whole website
==========================

The Allegro website is basically a custom templating system
implemented in Python which transforms the templates found in the
``src`` directory with all the available languages found in the
``data`` directory. Translators only modify files in the ``data``
directory and the python script has basically not been updated for
years because it works according to our requirements.  The Python
script itself is driven by GNU Make.

This script is much longer in execution and tasks than the previous
one.  First, it tries to update the CVS files. This consumes local
network bandwidth.  Then, dependencies are generated for both
templates and eventual binary files which may be uploaded manually
by webmasters. This, along with the processing of the templates is
what takes most time. On a PII800 machine both tasks complete in
about two minutes if *all* the templates are to be processed. This
happens seldom, so processing time should be quite short most of
the time.


Contact
=======

Should problems arise, and the author of the cron
entry not answer emails, you can send an email to
alleg-developers@lists.sourceforge.net, where other administrators
of the Allegro project are available.


Current user running this script
================================

Right now the user ``gradha`` is running this script from his
crontab.