NAME
pkit_setup_db.pl
SYNOPSIS
This script creates the tables, pkit_user and sessions in the specified database.
REQUIREMENTS
A DBD driver that matches the specified database. In the case of the Apache::PageKit example, DBD::SQLite is required.
USAGE
pkit_setup_db.pl driver dbName userName auth
- -
-
driver
is the name of the DBD driver that matches the database being used. - -
-
dbName
is the name of the database. When using file-based databases, as with for instance SQLite, it will be the file name. - -
-
userName
is the user name that will be used to login and create the tables in the database. - -
-
auth
is the authentication string needed to log into the database.
DESCRIPTION
The script logs into the specified database using the specified user name and authentication string. It then creates the tables pkit_user and sessions.
CREATE TABLE pkit_user ( user_id CHAR(8), login CHAR(255), email CHAR(255), passwd CHAR(255) )
CREATE TABLE sessions ( id char(32) not null primary key, a_session text )
This may be useful for starting an application, using Apache::PageKit.
EXAMPLES
pkit_setup_db.pl dbfile "" ""
pkit_setup_db.pl pagekit "" ""
pkit_setup_db.pl pagekit pageusr 'Q#Se$Re;w'
BUGS
NOTES
For the Apache::PageKit demo, the SQLite driver must be used. The script will produce the database file in the cwd.
CREDITS
Boris Zentner <bzm@2bz.de>, for the initial script,
pkit_setup_sqlite_dbfile.pl, where this script was copied
and modified from.
AUTHOR
Pieter du Preez <pdupreez@sodoz.com>