Jesper Nøhr > PheMail-Vhost > PheMail::Vhost

Download:
PheMail-Vhost-0.14.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.14   Source  

NAME ^

PheMail::Vhost - Perl extension for Apache MySQL Vhost loading

SYNOPSIS ^

  use PheMail::Vhost;
  alterSqlFromString("backendtype","user","password","mysqlhost","myip");
  PheMail::LoadVhosts(\%VirtualHost);

DESCRIPTION ^

PheMail::Vhost loads vhosts into httpd.conf (Apache 1.3.x) collected from a MySQL database. Used in Project PheMail. It is possible to extend it's features to do a lot of other stuff. Here's a sample MySQL structure:

CREATE TABLE `vhosts` ( `id` int(11) NOT NULL auto_increment, `hoster` varchar(15) NOT NULL default '192.168.1.1', `sname` varchar(255) NOT NULL default '', `droot` varchar(255) NOT NULL default '', `sadmin` varchar(255) NOT NULL default 'spike@printf.dk', `domain` varchar(255) NOT NULL default '', `soptions` varchar(255) NOT NULL default '', `htaccess` text NOT NULL, `users` text NOT NULL, `extensions` text NOT NULL, `redirect` varchar(255) NOT NULL default '', `eredirect` enum('1','0') NOT NULL default '0', `open_basedir` enum('1','0') NOT NULL default '1', `safe_mode` enum('1','0') NOT NULL default '0', `magic_quotes` enum('1','0') NOT NULL default '1', `enableauth` enum('1','0') NOT NULL default '0', `authname` varchar(255) NOT NULL default 'PheMail Protected Area', `disablefunc` text NOT NULL, PRIMARY KEY (`id`) ) TYPE=MyISAM;

The fields should be pretty selfexplanatory. Since this is a part of a project, I don't really support the structure.

EXPORT

LoadVhosts(); ReportSql(); altersqlFromString();

AUTHOR ^

Jesper Noehr, <jesper@noehr.org>

SEE ALSO ^

perl, DBI

TODO ^

I rewrote the code, it seems pretty stable as it is now. I will need to add more features later.

syntax highlighting: