How to set up Sql-Ledger to serve from AOLserver

From AOLserver Wiki
Revision as of 21:50, 5 February 2006 by 24.20.69.247 (talk)
Jump to navigation Jump to search

Install SQL-Ledger with the following modifications:

Note that I'm using this on an isolated LAN so have not done any testing to verify the integrity of SQL-Ledger security on it.

Be sure AOLserver is installed, and shutdown.

We adapt the instructions for setting setting up httpd (aolserver's nsd in this case):

  • Download and build the AOLserver nscgi module. Usually nscgi is already included with the AOLserver distribution.

You can see examples of how to build AOLserver modules by reading the AOLserver install docs for OpenACS 5.1.

In the OpenACS config.tcl file, activate the nscgi module in this section:

ns_section ns/server/${server}/modules 
ns_param   nscgi              ${bindir}/nscgi.so

And modify the nscgi module configuration in config.tcl. Jon Griffin has some advice about doing this with security in mind http://jongriffin.com/static/consultant/nscgi Include something like the following. Note that this section needs updating based on GJ's suggestions:

ns_section "ns/server/${server}/module/nscgi"
ns_param   map "GET  /sql-ledger/*.pl /usr/local/sql-ledger"
ns_param   map "POST /sql-ledger/*.pl /usr/local/sql-ledger"
ns_param   Interps CGIinterps

ns_section "ns/interps/CGIinterps"
ns_param   .pl "/usr/bin/perl"

Do *not* put the SQL-Ledger directory in the AOLserver's pageroot directory. Put it in the /usr/local directory per SL docs:

cd /usr/local
mv /sql-ledger /usr/local/sql-ledger/.
# set permissions to match the rest of the aolserver files, for example:
cd /usr/local/
chown -R nsadmin:web sql-ledger
chmod -R 770 sql-ledger 

Follow the SL directions to create a SQL-Ledger database and user for PostgreSQL, and proceed with the configuration in the SL README. Hopefully you see a login page at http://yourservername:port/sql-ledger/admin.pl and are able to follow standard SQL-Ledger configuration directions.