[vhffs-dev] [810] Renamed all robots

[ Thread Index | Date Index | More vhffs.org/vhffs-dev Archives ]


Revision: 810
Author:   gradator
Date:     2007-08-30 00:05:34 +0000 (Thu, 30 Aug 2007)

Log Message:
-----------
Renamed all robots

Modified Paths:
--------------
    trunk/vhffs-robots/Makefile.am

Added Paths:
-----------
    trunk/vhffs-robots/src/cvs_create.pl
    trunk/vhffs-robots/src/cvs_delete.pl
    trunk/vhffs-robots/src/cvs_refused.pl
    trunk/vhffs-robots/src/dns_create.pl
    trunk/vhffs-robots/src/dns_delete.pl
    trunk/vhffs-robots/src/dns_refused.pl
    trunk/vhffs-robots/src/group_create.pl
    trunk/vhffs-robots/src/group_delete.pl
    trunk/vhffs-robots/src/group_refused.pl
    trunk/vhffs-robots/src/group_setquota.pl
    trunk/vhffs-robots/src/group_updatequotaused.pl
    trunk/vhffs-robots/src/group_updatequotausedrepository.pl
    trunk/vhffs-robots/src/mail_create.pl
    trunk/vhffs-robots/src/mail_delete.pl
    trunk/vhffs-robots/src/mail_refused.pl
    trunk/vhffs-robots/src/mailinglist_create.pl
    trunk/vhffs-robots/src/mailinglist_delete.pl
    trunk/vhffs-robots/src/mailinglist_refused.pl
    trunk/vhffs-robots/src/mysql_create.pl
    trunk/vhffs-robots/src/mysql_delete.pl
    trunk/vhffs-robots/src/mysql_dump.pl
    trunk/vhffs-robots/src/mysql_modify.pl
    trunk/vhffs-robots/src/mysql_refused.pl
    trunk/vhffs-robots/src/pgsql_create.pl
    trunk/vhffs-robots/src/pgsql_delete.pl
    trunk/vhffs-robots/src/pgsql_dump.pl
    trunk/vhffs-robots/src/pgsql_modify.pl
    trunk/vhffs-robots/src/pgsql_refused.pl
    trunk/vhffs-robots/src/repository_create.pl
    trunk/vhffs-robots/src/repository_delete.pl
    trunk/vhffs-robots/src/repository_refused.pl
    trunk/vhffs-robots/src/repository_setquota.pl
    trunk/vhffs-robots/src/repository_stats.pl
    trunk/vhffs-robots/src/svn_create.pl
    trunk/vhffs-robots/src/svn_delete.pl
    trunk/vhffs-robots/src/svn_refused.pl
    trunk/vhffs-robots/src/user_create.pl
    trunk/vhffs-robots/src/user_delete.pl
    trunk/vhffs-robots/src/web_create.pl
    trunk/vhffs-robots/src/web_delete.pl
    trunk/vhffs-robots/src/web_refused.pl
    trunk/vhffs-robots/src/web_stats.pl

Removed Paths:
-------------
    trunk/vhffs-robots/src/create_cvs.pl
    trunk/vhffs-robots/src/create_dns.pl
    trunk/vhffs-robots/src/create_groups.pl
    trunk/vhffs-robots/src/create_homes.pl
    trunk/vhffs-robots/src/create_mail.pl
    trunk/vhffs-robots/src/create_ml.pl
    trunk/vhffs-robots/src/create_mysql.pl
    trunk/vhffs-robots/src/create_pgsql.pl
    trunk/vhffs-robots/src/create_repository.pl
    trunk/vhffs-robots/src/create_svn.pl
    trunk/vhffs-robots/src/create_web.pl
    trunk/vhffs-robots/src/delete_cvs.pl
    trunk/vhffs-robots/src/delete_dns.pl
    trunk/vhffs-robots/src/delete_group.pl
    trunk/vhffs-robots/src/delete_mail.pl
    trunk/vhffs-robots/src/delete_ml.pl
    trunk/vhffs-robots/src/delete_mysql.pl
    trunk/vhffs-robots/src/delete_pgsql.pl
    trunk/vhffs-robots/src/delete_repository.pl
    trunk/vhffs-robots/src/delete_svn.pl
    trunk/vhffs-robots/src/delete_users.pl
    trunk/vhffs-robots/src/delete_web.pl
    trunk/vhffs-robots/src/dump_mysql.pl
    trunk/vhffs-robots/src/dump_pgsql.pl
    trunk/vhffs-robots/src/fix_quota.pl
    trunk/vhffs-robots/src/fix_quota_repository.pl
    trunk/vhffs-robots/src/generate_repositorystats.pl
    trunk/vhffs-robots/src/generate_webstats.pl
    trunk/vhffs-robots/src/modify_mysql.pl
    trunk/vhffs-robots/src/modify_pgsql.pl
    trunk/vhffs-robots/src/refused_cvs.pl
    trunk/vhffs-robots/src/refused_dns.pl
    trunk/vhffs-robots/src/refused_groups.pl
    trunk/vhffs-robots/src/refused_mail.pl
    trunk/vhffs-robots/src/refused_ml.pl
    trunk/vhffs-robots/src/refused_mysql.pl
    trunk/vhffs-robots/src/refused_postgres.pl
    trunk/vhffs-robots/src/refused_repository.pl
    trunk/vhffs-robots/src/refused_svn.pl
    trunk/vhffs-robots/src/refused_web.pl
    trunk/vhffs-robots/src/update_quota_used.pl
    trunk/vhffs-robots/src/update_quota_used_repository.pl


Modified: trunk/vhffs-robots/Makefile.am
===================================================================
--- trunk/vhffs-robots/Makefile.am	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/Makefile.am	2007-08-30 00:05:34 UTC (rev 810)
@@ -19,56 +19,55 @@
     misc/vhffs_post_commit.pl
 
 bots_SCRIPTS = \
-	src/create_cvs.pl \
-	src/create_dns.pl \
-	src/create_groups.pl \
-	src/create_homes.pl \
-	src/create_mail.pl \
-	src/create_ml.pl \
-	src/create_mysql.pl \
-	src/create_pgsql.pl \
-	src/create_repository.pl \
-	src/create_svn.pl \
 	src/create_viewvcconf.pl \
-	src/create_web.pl \
+	src/cvs_create.pl \
+	src/cvs_delete.pl \
 	src/cvs_fixperms.pl \
-	src/delete_cvs.pl \
-	src/delete_dns.pl \
-	src/delete_group.pl \
-	src/delete_mail.pl \
-	src/delete_ml.pl \
-	src/delete_mysql.pl \
-	src/delete_pgsql.pl \
-	src/delete_repository.pl \
-	src/delete_svn.pl \
-	src/delete_users.pl \
-	src/delete_web.pl \
-	src/dump_mysql.pl \
-	src/dump_pgsql.pl \
-	src/fix_quota.pl \
-	src/fix_quota.pl \
-	src/fix_quota_repository.pl \
-	src/generate_repositorystats.pl \
-	src/generate_webstats.pl \
+	src/cvs_refused.pl \
+	src/dns_create.pl \
+	src/dns_delete.pl \
+	src/dns_refused.pl \
+	src/group_create.pl \
+	src/group_delete.pl \
+	src/group_refused.pl \
+	src/group_setquota.pl \
+	src/group_updatequotaused.pl \
+	src/group_updatequotausedrepository.pl \
 	src/listengine_publicarchives.pl \
+	src/mail_create.pl \
+	src/mail_delete.pl \
+	src/mailinglist_create.pl \
+	src/mailinglist_delete.pl \
+	src/mailinglist_refused.pl \
 	src/mailing.pl \
-	src/modify_mysql.pl \
-	src/modify_pgsql.pl \
-	src/refused_cvs.pl \
-	src/refused_dns.pl \
-	src/refused_groups.pl \
-	src/refused_mail.pl \
-	src/refused_ml.pl \
-	src/refused_mysql.pl \
-	src/refused_postgres.pl \
-	src/refused_repository.pl \
-	src/refused_svn.pl \
-	src/refused_web.pl \
+	src/mail_refused.pl \
+	src/mysql_create.pl \
+	src/mysql_delete.pl \
+	src/mysql_dump.pl \
+	src/mysql_modify.pl \
+	src/mysql_refused.pl \
+	src/pgsql_create.pl \
+	src/pgsql_delete.pl \
+	src/pgsql_dump.pl \
+	src/pgsql_modify.pl \
+	src/pgsql_refused.pl \
+	src/repository_create.pl \
+	src/repository_delete.pl \
+	src/repository_refused.pl \
+	src/repository_setquota.pl \
+	src/repository_stats.pl \
+	src/svn_create.pl \
+	src/svn_delete.pl \
 	src/svn_public.pl \
+	src/svn_refused.pl \
 	src/svn_websvn.pl \
-	src/update_quota_used.pl \
-	src/update_quota_used_repository.pl \
-	src/user_group.pl
+	src/user_create.pl \
+	src/user_delete.pl \
+	src/user_group.pl \
+	src/web_create.pl \
+	src/web_delete.pl \
+	src/web_refused.pl \
+	src/web_stats.pl
 
 # Define the substitution we need to point perl script at correct location
 do_sed = $(SED) --in-place \

Deleted: trunk/vhffs-robots/src/create_cvs.pl
===================================================================
--- trunk/vhffs-robots/src/create_cvs.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_cvs.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,61 +0,0 @@
-#!%PERL%
-
-
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Cvs;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "cvs" );
-
-my $cvs = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef  );
-my $c;
-
-foreach $c ( @{$cvs} )
-{
-		if( Vhffs::Robots::Cvs::create_cvs( $c ) > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "CVS: repository %s is created" , $c->get_cvsroot ) , $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "CVS: cannot create %s CVS repository" , $c->get_cvsroot ) , $vhffs);
-		}
-}
-
-Vhffs::Robots::unlock( $vhffs , "cvs" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/create_dns.pl
===================================================================
--- trunk/vhffs-robots/src/create_dns.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_dns.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,71 +0,0 @@
-#!%PERL%
-
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-
-use Vhffs::Services::DNS;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-use strict;
-
-#Init VHFFS subsystem
-my $vhffs = init Vhffs::Main;
-
-
-#Lock if specified in the config-file
-Vhffs::Robots::lock( $vhffs , "dns" );
-
-#Get all DNS objects to create
-my $tocreate = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
-my $dns;
-
-if( defined $tocreate )
-{
-	foreach $dns ( @{$tocreate} )
-	{
-        $dns->set_status( Vhffs::Constants::ACTIVATED );
-        if( $dns->commit > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Create domain %s" , $dns->get_domain  ) , $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Cannot create domain %s" , $dns->get_domain  ) , $vhffs);
-		}
-
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "dns" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/create_groups.pl
===================================================================
--- trunk/vhffs-robots/src/create_groups.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_groups.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Group;
-use Vhffs::Robots;
-use Vhffs::Robots::Group;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "usergroup" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
-
-my $group;
-
-foreach $group ( @{$groups} )
-{
-	if( Vhffs::Robots::Group::create_groupdir( $vhffs , $group ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "cannot create group %s " , $group->get_groupname ) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "create group %s " , $group->get_groupname ) , $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "usergroup" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/create_homes.pl
===================================================================
--- trunk/vhffs-robots/src/create_homes.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_homes.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-
-#This robot creates home directory of each users
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::User;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "usergroup" );
-
-my $users = Vhffs::User::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef );
-my $user;
-
-foreach $user ( @{$users} )
-{
-	if( Vhffs::Robots::User::create_home( $vhffs , $user ) != 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Error while creating home for %s" , $user->get_username) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Creating home/account for %s" , $user->get_username) , $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "usergroup" );
-
-exit 0;
-

Deleted: trunk/vhffs-robots/src/create_mail.pl
===================================================================
--- trunk/vhffs-robots/src/create_mail.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_mail.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,68 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-#This robot create mail domain
-#It actives it
-
-# FIXME : This robot is unnecessary, we just have to activate mailbox on creation
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Services::Mail;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mail" );
-
-my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
-my $m;
-
-
-foreach $m ( @{$mails} )
-{
-	$m->add_history( "Robots will activated this mail domain" );
-	$m->set_status( Vhffs::Constants::ACTIVATED );
-	if( $m->commit > 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Create mail domain %s" , $m->get_domain ) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "cannot create mail domain %s" , $m->get_domain ) , $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "mail" );
-
-
-exit 0;

Deleted: trunk/vhffs-robots/src/create_ml.pl
===================================================================
--- trunk/vhffs-robots/src/create_ml.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_ml.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,64 +0,0 @@
-#!%PERL%
-
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Constants;
-use Vhffs::Services::MailingList;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "ml" );
-
-my $mls  = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
-my $ml;
-
-
-foreach $ml ( @{$mls} )
-{
-
-	$ml->set_status( Vhffs::Constants::ACTIVATED );
-	if( $ml->commit < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot create list %s", $ml->get_title ), $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Create list %s", $ml->get_title ), $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "ml" );
-
-exit 0;
-

Deleted: trunk/vhffs-robots/src/create_mysql.pl
===================================================================
--- trunk/vhffs-robots/src/create_mysql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_mysql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,66 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use strict;
-use POSIX;
-use locale;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Services::Mysql;
-use Vhffs::Robots::Mysql;
-use Vhffs::Constants;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mysql" );
-
-my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef );
-my $db;
-
-
-foreach $db ( @{$dbs} )
-{
-	if( Vhffs::Robots::Mysql::create_db( $vhffs , $db ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf("Cannot create MySQL database %s",$db->get_dbname) , $vhffs);
-
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf("Create MySQL database %s",$db->get_dbname) , $vhffs);
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "mysql" );
-exit 0;

Deleted: trunk/vhffs-robots/src/create_pgsql.pl
===================================================================
--- trunk/vhffs-robots/src/create_pgsql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_pgsql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,60 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Pgsql;
-use Vhffs::Main;
-use Vhffs::Robots;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "pgsql" );
-
-my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
-my $db;
-
-foreach $db ( @{$dbs} )
-{
-	if( Vhffs::Robots::Pgsql::create_db( $vhffs , $db ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf("Cannot create PostgreSQL database %s",$db->get_dbname) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf("Create PostgreSQL database %s",$db->get_dbname) , $vhffs);
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "pgsql" );
-exit( 0 );

Deleted: trunk/vhffs-robots/src/create_repository.pl
===================================================================
--- trunk/vhffs-robots/src/create_repository.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_repository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,61 +0,0 @@
-#!%PERL%
-
-
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Repository;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "repository" );
-
-my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef  );
-my $repo;
-
-foreach $repo ( @{$repos} )
-{
-		if( Vhffs::Robots::Repository::create_repository( $repo ) > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "REPOSITORY: Download repository %s is created" , $repo->get_name ) , $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "REPOSITORY: Cannot create download repository %s" , $repo->get_name ) , $vhffs);
-		}
-}
-
-Vhffs::Robots::unlock( $vhffs , "repository" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/create_svn.pl
===================================================================
--- trunk/vhffs-robots/src/create_svn.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_svn.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,58 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Robots::Svn;
-use Vhffs::Services::Svn;
-use Vhffs::Constants;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "svn" );
-
-my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION);
-my $svn;
-foreach $svn ( @{$repos} )
-{
-	if( Vhffs::Robots::Svn::create_repo( $vhffs , $svn ) < 0 ) {
-    		Vhffs::Robots::vhffs_log( sprintf( "Cannot create SVN %s" , $svn->get_reponame ), $vhffs);
-	} else {
-		Vhffs::Robots::vhffs_log( sprintf( "Create SVN %s" , $svn->get_reponame ), $vhffs);
-		symlink('%VHFFS_BOTS_DIR%/misc/vhffs_post_commit.pl', $svn->get_dir().'/hooks/post-commit');
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "svn" );
-exit 0;

Deleted: trunk/vhffs-robots/src/create_web.pl
===================================================================
--- trunk/vhffs-robots/src/create_web.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/create_web.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Web;
-use Vhffs::Services::Web;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "web" );
-
-my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef, undef );
-my $web;
-
-foreach $web ( @{$webs} )
-{
-	if( Vhffs::Robots::Web::create_web( $vhffs , $web ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot create web %s" , $web->get_servername ) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Create web %s" , $web->get_servername ) , $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "web" );
-
-exit 0;
-

Copied: trunk/vhffs-robots/src/cvs_create.pl (from rev 798, trunk/vhffs-robots/src/create_cvs.pl)
===================================================================
--- trunk/vhffs-robots/src/cvs_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/cvs_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,61 @@
+#!%PERL%
+
+
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Cvs;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "cvs" );
+
+my $cvs = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef  );
+my $c;
+
+foreach $c ( @{$cvs} )
+{
+		if( Vhffs::Robots::Cvs::create_cvs( $c ) > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "CVS: repository %s is created" , $c->get_cvsroot ) , $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "CVS: cannot create %s CVS repository" , $c->get_cvsroot ) , $vhffs);
+		}
+}
+
+Vhffs::Robots::unlock( $vhffs , "cvs" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/cvs_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_cvs.pl)
===================================================================
--- trunk/vhffs-robots/src/cvs_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/cvs_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,66 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Cvs;
+use Vhffs::Services::Cvs;
+use Vhffs::Constants;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "cvs" );
+
+my $lol = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $cvs;
+
+foreach $cvs ( @{$lol} )
+{
+    if( Vhffs::Robots::Cvs::delete_cvs( $cvs ) > 0 ) {
+        Vhffs::Robots::vhffs_log( sprintf( "Delete files from %s", $cvs->get_cvsroot ), $vhffs);
+    } else {
+        Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from %s", $cvs->get_cvsroot ), $vhffs);
+    }
+
+    if( $cvs->delete > 0 ) {
+        Vhffs::Robots::vhffs_log( sprintf( "Delete CVS object %s", $cvs->get_cvsroot ), $vhffs);
+    } else {
+        Vhffs::Robots::vhffs_log( sprintf( "Cannot delete CVS object %s", $cvs->get_cvsroot ), $vhffs);
+    }
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "cvs" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/cvs_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_cvs.pl)
===================================================================
--- trunk/vhffs-robots/src/cvs_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/cvs_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,87 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Services::Cvs;
+use Vhffs::Robots;
+use Vhffs::Robots::Cvs;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "cvs" );
+
+$objects = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	$user = $object->get_user;
+	$lang = Vhffs::Panel::User::get_lang( $user );
+	setlocale( LC_ALL , $lang ) if( defined $lang );
+	if( defined $user ) {
+		$message  = sprintf( gettext("Your CVS request : %s ") , $object->get_cvsroot);
+		$message .= gettext("has been refused by the Moderators team")."\n";
+		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+		if( length( $object->get_description ) > 1 ) {
+		    $message .= gettext("Reason given : ");
+		    $message .= $object->get_description . "\n";
+		}
+		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+		$message .= gettext("Cheers,")."\n";
+		$message .= gettext("The Moderator and Admin team");
+
+		$subject = gettext("Your CVS repository request");
+		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+	}
+	
+	$object->delete;
+}
+
+Vhffs::Robots::unlock( $vhffs , "cvs" );
+exit 0;

Deleted: trunk/vhffs-robots/src/delete_cvs.pl
===================================================================
--- trunk/vhffs-robots/src/delete_cvs.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_cvs.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,66 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Cvs;
-use Vhffs::Services::Cvs;
-use Vhffs::Constants;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "cvs" );
-
-my $lol = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $cvs;
-
-foreach $cvs ( @{$lol} )
-{
-    if( Vhffs::Robots::Cvs::delete_cvs( $cvs ) > 0 ) {
-        Vhffs::Robots::vhffs_log( sprintf( "Delete files from %s", $cvs->get_cvsroot ), $vhffs);
-    } else {
-        Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from %s", $cvs->get_cvsroot ), $vhffs);
-    }
-
-    if( $cvs->delete > 0 ) {
-        Vhffs::Robots::vhffs_log( sprintf( "Delete CVS object %s", $cvs->get_cvsroot ), $vhffs);
-    } else {
-        Vhffs::Robots::vhffs_log( sprintf( "Cannot delete CVS object %s", $cvs->get_cvsroot ), $vhffs);
-    }
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "cvs" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_dns.pl
===================================================================
--- trunk/vhffs-robots/src/delete_dns.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_dns.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,65 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Services::DNS;
-use Vhffs::Main;
-
-use strict;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "dns" );
-
-my $dns;
-my $todelete = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-
-if( defined $todelete )
-{
-	foreach $dns ( @{$todelete} )
-	{
-		if( $dns->delete > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Delete %s", $dns->get_domain ), $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete domain name %s", $dns->get_domain ), $vhffs);
-		}
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "dns" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_group.pl
===================================================================
--- trunk/vhffs-robots/src/delete_group.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_group.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,157 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Group;
-use Vhffs::Main;
-use Vhffs::Group;
-use Vhffs::Constants;
-use Vhffs::Services::Cvs;
-use Vhffs::Services::DNS;
-use Vhffs::Services::Web;
-use Vhffs::Services::MailingList;
-use Vhffs::Services::Mail;
-use Vhffs::Services::Mysql;
-use Vhffs::Services::Pgsql;
-use Vhffs::Services::Svn;
-use Vhffs::Robots;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "usergroup" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $group;
-my $objects;
-my $object;
-my $ok;
-
-foreach $group ( @{$groups} )
-{
-	Vhffs::Robots::vhffs_log( sprintf(  "Will try to delete group %s",  $group->get_groupname), $vhffs);
-	$ok = 1;
-
-    $objects = Vhffs::Services::Cvs::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0 );
-    foreach $object ( @{$objects} )
-    {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain cvs for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-    }
-
-    $objects = Vhffs::Services::Svn::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0);
-    foreach $object ( @{$objects} )
-    {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain svn for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-    }
-
-    $objects = Vhffs::Services::DNS::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0);
-    foreach $object ( @{$objects} )
-    {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain dns for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-    }
-
-    $objects = Vhffs::Services::Mysql::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0 );
-    foreach $object ( @{$objects} )
-    {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain mysql for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-    }
-
-    $objects = Vhffs::Services::Pgsql::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0 );
-   foreach $object ( @{$objects} )
-   {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain pgsql for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-   }
-
-
-    $objects = Vhffs::Services::Web::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0 );
-   foreach $object ( @{$objects} )
-   {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain website for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-   }
-    
-	$objects = Vhffs::Services::MailingList::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0);
-   foreach $object ( @{$objects} )
-   {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain list for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		$object->commit;
-   }
-
-
-	$objects = Vhffs::Services::Mail::getall( $vhffs , undef , undef , $group );
-	$ok = 0 if( @$objects != 0 );
-   foreach $object ( @{$objects} )
-   {
-		Vhffs::Robots::vhffs_log( sprintf( "Remain mail for group %s before delete" , $group->get_groupname ), $vhffs);
-        $object->set_status( Vhffs::Constants::TO_DELETE );
-		if( $object->commit < 0 )
-		{
-			Vhffs::Robots::vhffs_log( "Error in delete group" , $vhffs);
-		}
-   }
-
-
-	if( $ok == 1 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Delete group %s" , $group->get_groupname ), $vhffs);
-		Vhffs::Robots::Group::delete( $vhffs , $group );
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot elete group %s, items remains" , $group->get_groupname ), $vhffs);
-	}
-
-}
-
-Vhffs::Robots::unlock( $vhffs , "usergroup" );
-
-exit( 0 );
-

Deleted: trunk/vhffs-robots/src/delete_mail.pl
===================================================================
--- trunk/vhffs-robots/src/delete_mail.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_mail.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,67 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-
-use Vhffs::Services::Mail;
-use Vhffs::Services::MailingList;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mail" );
-
-my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $mail;
-my $lists;
-my $list;
-foreach $mail ( @{$mails} )
-{
-    my $lists = Vhffs::Services::MailingList::getall( $vhffs , undef , undef , undef , $mail->get_domain );
-	if( @$lists != 0) {
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete mail domain %s, remains lists" , $mail->get_domain ) , $vhffs);
-		foreach $list ( @{$lists} ) {
-			$list->set_status( Vhffs::Constants::TO_DELETE );
-			$list->commit;
-		}
-	} else {
-		Vhffs::Robots::vhffs_log( sprintf( "Delete mail domain %s" , $mail->get_domain ) , $vhffs);
-		$mail->delete;
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "mail" );
-exit 0;
-

Deleted: trunk/vhffs-robots/src/delete_ml.pl
===================================================================
--- trunk/vhffs-robots/src/delete_ml.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_ml.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,59 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Constants;
-use Vhffs::Robots;
-use Vhffs::Services::MailingList;
-
-
-my $vhffs  = init Vhffs::Main;
-Vhffs::Robots::lock( $vhffs , "ml" );
-my $mls  = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $ml;
-
-foreach $ml ( @{$mls} )
-{
-	if( $ml->delete < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete list %s" , $ml->get_listname ) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Delete list %s" , $ml->get_listname ) , $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "ml" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_mysql.pl
===================================================================
--- trunk/vhffs-robots/src/delete_mysql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_mysql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Robots::Mysql;
-use Vhffs::Services::Mysql;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mysql" );
-
-my $dbs = Vhffs::Services::Mysql::getall( $vhffs  , Vhffs::Constants::TO_DELETE , undef , undef  );
-my $db;
-
-
-foreach $db ( @{$dbs} )
-{
-	if( Vhffs::Robots::Mysql::delete_db( $vhffs , $db ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete MySQL database %s" , $db->get_dbname ), $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Delete MySQL database %s" , $db->get_dbname ), $vhffs);
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "mysql" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_pgsql.pl
===================================================================
--- trunk/vhffs-robots/src/delete_pgsql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_pgsql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,61 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Services::Pgsql;
-use Vhffs::Robots::Pgsql;
-use Vhffs::Main;
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "pgsql" );
-
-my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::TO_DELETE , undef , undef  );
-my $db;
-
-
-foreach $db ( @{$dbs} )
-{
-	if(  Vhffs::Robots::Pgsql::delete_db( $vhffs , $db ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete PostgreSQL database %s" , $db->get_dbname ), $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Delete PostgreSQL database %s" , $db->get_dbname ), $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "pgsql" );
-
-exit 0;
-

Deleted: trunk/vhffs-robots/src/delete_repository.pl
===================================================================
--- trunk/vhffs-robots/src/delete_repository.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_repository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,75 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots::Repository;
-use Vhffs::Services::Repository;
-use Vhffs::Constants;
-use Vhffs::Robots;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "repository" );
-
-my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $repo;
-
-foreach $repo ( @{$repos} )
-{
-    if( defined $repo )
-    {
-        if( Vhffs::Robots::Repository::delete_repository( $repo ) > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Delete files from %s", $repo->get_name ), $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from %s", $repo->get_name ), $vhffs);
-		}
-		
-		if( $repo->delete > 0 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Deleted download repository object %s", $repo->get_name ), $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete download repository object %s", $repo->get_name ), $vhffs);
-		}
-    }
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "repository" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_svn.pl
===================================================================
--- trunk/vhffs-robots/src/delete_svn.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_svn.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Robots::Svn;
-use Vhffs::Services::Svn;
-use Vhffs::Constants;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "svn" );
-
-my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::TO_DELETE);
-my $svn;
-foreach $svn ( @{$repos} )
-{
-	if( Vhffs::Robots::Svn::delete_repo( $vhffs , $svn ) < 0 )	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from SVN repository %s" , $svn->get_reponame ), $vhffs);
-	} else {
-		Vhffs::Robots::vhffs_log( sprintf( "Delete files from SVN repository %s" , $svn->get_reponame ), $vhffs);
-	}
-
-	if( $svn->delete < 0 ) {
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete SVN repository object %s" , $svn->get_reponame ), $vhffs);
-	} else {
-		Vhffs::Robots::vhffs_log( sprintf( "Delete SVN repository object %s" , $svn->get_reponame ), $vhffs);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "svn" );
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_users.pl
===================================================================
--- trunk/vhffs-robots/src/delete_users.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_users.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,98 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Robots::User;
-use Vhffs::User;
-use Vhffs::Constants;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "usergroup" );
-
-my $lol = Vhffs::User::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $user;
-my $groups;
-my $group;
-foreach $user ( @{$lol} )
-{
-	$ok = 1;
-    if( defined $user ) 
-    {
-		$groups =  $user->get_groups;
-
-		if( defined $groups )
-		{
-			foreach $group ( @{$groups} )
-			{
-				Vhffs::Robots::vhffs_log( sprintf("Delete %s, remains group(s) : will delete %s " , $user->get_username , $group->get_groupname ) , $vhffs);
-				if( $group->get_owner_uid == $user->get_uid )
-				{
-					$ok = 0;
-					$group->set_status( Vhffs::Constants::TO_DELETE );
-					$group->commit;
-				}
-			}
-		}
-		
-		if( $ok == 1 )
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "USER delete user %s" , $user->get_username ) , $vhffs);
-        	if( Vhffs::Robots::User::delete( $vhffs, $user ) < 0 )
-			{
-				Vhffs::Robots::vhffs_log( sprintf("Cannot delete user files %s" , $user->get_username ) , $vhffs);
-			}
-			else
-			{
-				Vhffs::Robots::vhffs_log( sprintf("Delete user files %s" , $user->get_username ) , $vhffs);
-			}
-
-			if( $user->delete < 0 )
-			{
-				Vhffs::Robots::vhffs_log( sprintf("Cannot delete user object %s" , $user->get_username ) , $vhffs);
-			}
-			else
-			{
-				Vhffs::Robots::vhffs_log( sprintf("Delete user object %s" , $user->get_username ) , $vhffs);
-			}
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf("Cannot remove user %s, remains group(s)" , $user->get_username ) , $vhffs);
-		}
-    }
-}
-
-Vhffs::Robots::unlock( $vhffs , "usergroup" );
-exit 0;

Deleted: trunk/vhffs-robots/src/delete_web.pl
===================================================================
--- trunk/vhffs-robots/src/delete_web.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/delete_web.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,62 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Robots::Web;
-use Vhffs::Services::Web;
-use Vhffs::Main;
-use Vhffs::Constants;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "web" );
-
-my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::TO_DELETE );
-my $web;
-
-
-foreach $web ( @{$webs} )
-{
-	if( Vhffs::Robots::Web::delete( $vhffs , $web ) < 0 )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete web %s" , $web->get_servername ) , $vhffs);
-	}
-	else
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Delete web %s" , $web->get_servername ) , $vhffs);
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "web" );
-exit 0;

Copied: trunk/vhffs-robots/src/dns_create.pl (from rev 798, trunk/vhffs-robots/src/create_dns.pl)
===================================================================
--- trunk/vhffs-robots/src/dns_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/dns_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,71 @@
+#!%PERL%
+
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+
+use Vhffs::Services::DNS;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+use strict;
+
+#Init VHFFS subsystem
+my $vhffs = init Vhffs::Main;
+
+
+#Lock if specified in the config-file
+Vhffs::Robots::lock( $vhffs , "dns" );
+
+#Get all DNS objects to create
+my $tocreate = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
+my $dns;
+
+if( defined $tocreate )
+{
+	foreach $dns ( @{$tocreate} )
+	{
+        $dns->set_status( Vhffs::Constants::ACTIVATED );
+        if( $dns->commit > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Create domain %s" , $dns->get_domain  ) , $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Cannot create domain %s" , $dns->get_domain  ) , $vhffs);
+		}
+
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "dns" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/dns_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_dns.pl)
===================================================================
--- trunk/vhffs-robots/src/dns_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/dns_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,65 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Services::DNS;
+use Vhffs::Main;
+
+use strict;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "dns" );
+
+my $dns;
+my $todelete = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+
+if( defined $todelete )
+{
+	foreach $dns ( @{$todelete} )
+	{
+		if( $dns->delete > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Delete %s", $dns->get_domain ), $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete domain name %s", $dns->get_domain ), $vhffs);
+		}
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "dns" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/dns_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_dns.pl)
===================================================================
--- trunk/vhffs-robots/src/dns_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/dns_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,92 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Robots;
+use Vhffs::Group;
+use Vhffs::Services::DNS;
+use Vhffs::Panel::User;
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "dns" );
+
+$objects = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	if( defined $object )
+	{
+		$user = $object->get_user;
+		$lang = Vhffs::Panel::User::get_lang( $user );
+		setlocale( LC_ALL , $lang ) if( defined $lang );
+		if( defined $user )
+		{
+			$message  = sprintf( gettext("Your DNS hosting request for the domain : %s ") , $object->get_domain );
+			$message .= gettext("has been refused by the Moderators team")."\n";
+			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+			if( length( $object->get_description ) > 1 )
+			{
+			    $message .= gettext("Reason given : ");
+			    $message .= $object->get_description . "\n";
+			}
+			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+			$message .= gettext("Cheers,")."\n";
+			$message .= gettext("The Moderator and Admin team");
+
+			$subject = gettext("Your DNS hosting request");
+			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+		}
+		
+		$object->delete;
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "dns" );
+exit 0;

Deleted: trunk/vhffs-robots/src/dump_mysql.pl
===================================================================
--- trunk/vhffs-robots/src/dump_mysql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/dump_mysql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,85 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-########################################################
-# This robot make dump for each MySQL database
-# and put it on each group directory
-#
-
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Functions;
-use Vhffs::Services::Mysql;
-use Vhffs::Robots;
-
-my $vhffs = init Vhffs::Main; 
-
-Vhffs::Robots::lock( $vhffs , "dumpmysql" );
-
-my $objs  = Vhffs::Services::Mysql::getall( $vhffs  );
-my $admin_dbuser = $vhffs->get_config->get_mysql_admin_username;
-my $admin_dbpass = $vhffs->get_config->get_mysql_admin_pass;
-my $admin_dbhost = $vhffs->get_config->get_mysql_admin_host;
-my $mysqldumppath = $vhffs->get_config->get_mysql_mysqldump_path;
-
-my $obj;
-my $group;
-my $groupname;
-
-die "Error, mysqldump is not present on this system in path \"$mysqldumppath\"\n" unless( -x $mysqldumppath );
-
-foreach $obj ( @{$objs} )
-{
-		$groupname = Vhffs::Group::get_name_by_gid( $vhffs , $obj->get_owner_gid );
-		my $dbname = $obj->get_dbname;
-		my $dir = Vhffs::Functions::hash_groupname( $groupname , $vhffs );
-		if( -d $dir )
-		{
-			my $file = $dir."/".$dbname.".mysql.dump";
-			my $cmd = "$mysqldumppath -u $admin_dbuser -h $admin_dbhost -p$admin_dbpass $dbname > $file";
-			system( $cmd );
-
-			#Change the chmod if the backup succeed
-			if( -f $file )
-			{
-				chown( $obj->get_owner_uid , $obj->get_owner_gid , $file );
-				chmod( 0660 , $file );
-			}
-			
-		}
-}
-
-Vhffs::Robots::unlock( $vhffs , "dumpmysql" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/dump_pgsql.pl
===================================================================
--- trunk/vhffs-robots/src/dump_pgsql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/dump_pgsql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,86 +0,0 @@
-#!/usr/bin/perl
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-########################################################
-# This robot make dump for each MySQL database
-# and put it on each group directory
-#
-
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Functions;
-use Vhffs::Services::Pgsql;
-use Vhffs::Robots;
-
-my $vhffs = init Vhffs::Main; 
-
-Vhffs::Robots::lock( $vhffs , "dumppgsql" );
-
-my $objs  = Vhffs::Services::Pgsql::getall( $vhffs  );
-my $admin_dbuser = $vhffs->get_config->get_pgsql_admin_username;
-my $admin_dbpass = $vhffs->get_config->get_pgsql_admin_pass;
-my $admin_dbhost = $vhffs->get_config->get_pgsql_admin_host;
-my $pgdumppath = $vhffs->get_config->get_pgsql_pgdump_path;
-
-my $obj;
-my $group;
-my $groupname;
-
-die "Error, pg_dump is not present on this system in path \"$pgdumppath\"\n" unless( -x $pgdumppath );
-
-foreach $obj ( @{$objs} )
-{
-	$groupname = Vhffs::Group::get_name_by_gid( $vhffs , $obj->get_owner_gid );
-	my $dbname = $obj->get_dbname;
-	my $dir = Vhffs::Functions::hash_groupname( $groupname , $vhffs );
-	if( -d $dir )
-	{
-		my $file = $dir."/".$dbname.".pgsql.dump";
-		my $cmd = "$pgdumppath -U $admin_dbuser -h $admin_dbhost -b -Fc -Z6 -f $file $dbname";
-		system( $cmd );
-
-		print $cmd."\n";
-
-		#Change the chmod if the backup succeed
-		if( -f $file )
-		{
-			chown( $obj->get_owner_uid , $obj->get_owner_gid , $file );
-			chmod( 0660 , $file );
-		}		
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "dumppgsql" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/fix_quota.pl
===================================================================
--- trunk/vhffs-robots/src/fix_quota.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/fix_quota.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,90 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-require 5.004;
-use strict;
-use POSIX;
-use locale;
-use Locale::gettext;
-use Quota;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Group;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "setquota" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-my $group;
-my $blocks;
-my $user;
-my $users;
-my $inodes;
-my $dev = Quota::getqcarg($vhffs->get_config->get_datadir);
-
-foreach $group ( @{$groups} )
-{
-	$blocks = $group->get_quota * 1024;
-	$inodes = $group->get_quota * 1126400 / 100;
-
-	unless( Quota::setqlim($dev, $group->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
-	{
-		Vhffs::Robots::vhffs_log( sprintf( "Update quota for group %s set %s" , $group->get_groupname , $group->get_quota ) , $vhffs);
-	}
-	else
-	{
-		printf("Cannot update quota for group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
-	}
-}
-
-$users = Vhffs::User::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-
-foreach $user ( @{$users} )
-{
-    $blocks = 1024;
-	$inodes = 1126400 / 100;
-
-    unless( Quota::setqlim($dev, $user->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
-	{
-			Vhffs::Robots::vhffs_log( sprintf( "Update quota for user group %s set 1" , $user->get_username ) , $vhffs);
-	}
-	else
-	{
-		printf("Cannot update quota for group %s, reason: %s\n", $user->get_username, Quota::strerr);
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "setquota" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/fix_quota_repository.pl
===================================================================
--- trunk/vhffs-robots/src/fix_quota_repository.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/fix_quota_repository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,119 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-require 5.004;
-use strict;
-use POSIX;
-use locale;
-use Locale::gettext;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Group;
-use Vhffs::Services::Repository;
-use Quota;
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "setquotarepository" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-my $group;
-my $quota;
-my $blocks;
-my $inodes;
-my $repos;
-my $repo;
-my $users;
-my $user;
-my $dev = Quota::getqcarg($vhffs->get_config->get_datadir."/".Vhffs::Constants::REPOSITORYDIR);
-
-foreach $group ( @{$groups} )
-{
-	if( defined $group )
-	{
-		$quota = 0;
-		$blocks = 0;
-		$inodes = 0;
-
-		$repos = Vhffs::Services::Repository::getall_per_group( $vhffs, $group);
-		if( defined $repos )
-		{
-			foreach $repo ( @{$repos} )
-			{
-				if( defined $repo )
-				{
-					$quota += $repo->get_quota;
-					$blocks += $repo->get_quota * 1024;
-					$inodes += $repo->get_quota * 1126400 / 100;
-				}
-			}
-
-			unless( Quota::setqlim($dev, $group->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
-			{
-				Vhffs::Robots::vhffs_log( sprintf( "Update quota for repositories of group %s to %s MB" , $group->get_groupname , $quota ) , $vhffs);
-			}
-			else
-			{
-				printf("Cannot update quota for repositories of group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
-			}
-		}
-		else
-		{
-			# give no space for groups without download repository
-			if( Quota::setqlim($dev, $group->get_gid, 1, 1, 1, 1, 0, 1) )
-			{
-				printf("Cannot update quota for repositories of group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
-			}
-		}
-	}
-}
-
-
-# give no space for users
-$users = Vhffs::User::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-
-foreach $user ( @{$users} )
-{
-	if( defined $user )
-	{
-		# give no space for all primary groups of users
-		if( Quota::setqlim($dev, $user->get_gid, 1, 1, 1, 1, 0, 1) )
-		{
-			printf("Cannot update quota for repositories of primary group of user %s, reason %s\n", $user->get_username, Quota::strerr);
-		}
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "setquotarepository" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/generate_repositorystats.pl
===================================================================
--- trunk/vhffs-robots/src/generate_repositorystats.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/generate_repositorystats.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,250 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-#Your logs must be in format : "%V %h %l %u %t \"%r\" %>s %b"
-#So, add in your httpd.conf following lines :
-#LogFormat "%V %h %l %u %t \"%r\" %>s %b" vhffs
-#CustomLog /var/log/apache2/http.log vhffs
-
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Conf;
-use Vhffs::Functions;
-use Vhffs::Services::Repository;
-use Vhffs::Robots;
-
-
-my $vhffs = init Vhffs::Main;
-die "ERROR: Cannot init VHFFS !!!" if( ! defined $vhffs );
-
-my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-die "ERROR: Cannot fetch the list of repository\n" if( ! defined $repos );
-
-my $repoconf = Vhffs::Conf::get_repository_config();
-die "ERROR: A full repository configuration is needed to generate stats\n" if ( ! defined $repoconf );
-
-my $conf_datadir = Vhffs::Conf::get_datadir;
-my $log_incoming_root = $repoconf->{"log_incoming_root"};
-my $log_incoming_rotations = $repoconf->{"log_incoming_rotations"};
-my $log_incoming_compress = ( $repoconf->{"log_incoming_compress"} eq 'yes' ) ? 1 : 0;
-my $log_parsed_root = $repoconf->{"log_parsed_root"};
-my $log_parsed_rotation = $repoconf->{"log_parsed_rotation"};
-my $log_parsed_compress = ( $repoconf->{"log_parsed_compress"} eq 'yes' ) ? 1 : 0;
-my $log_awstats = $repoconf->{"log_awstats"};
-my $awstats_sample = $repoconf->{"log_awstats_sample"};
-my $log_apachelocal = ( $repoconf->{"log_apachelocal"} eq 'yes' ) ? 1 : 0;
-my $log_apachectl = $repoconf->{"log_apachectl"};
-
-die "ERROR: ".$log_incoming_root." is not a directory" if( ! -d $log_incoming_root );
-die "ERROR: ".$log_parsed_root." is not a directory" if( ! -d $log_parsed_root );
-die "ERROR: ".$log_awstats." does no exist" if( ! -f $log_awstats );
-die "ERROR: cannot find the awstat sample at ".$awstats_sample if( ! -f $awstats_sample );
-die "ERROR: cannot find the apache2ctl binary at ".$log_apachectl if( $log_apachelocal  &&  ! -f $log_apachectl );
-
-Vhffs::Robots::lock( $vhffs , "repositorystats" );
-
-my %repositorys;
-foreach ( @{$repos} )  {
-	$repositorys{$_->get_name} = 1;
-}
-
-my @downloadservers;
-my $downloadserver;
-my @files;
-
-# -- Rotate servers logs (all *.log files, I know that the suffix is hardcoded but I don't
-#    bother to add a configuration entry for that, it's already too complicated, and, who would
-#    like anything other than .log ? ).
-
-opendir( DIR , $log_incoming_root );
-@files = readdir( DIR );
-
-foreach( @files )  {
-	next if( /\./ );
-	if( -d $log_incoming_root."/".$_ )  {
-		push @downloadservers, $_;
-	}
-}
-closedir( DIR );
-
-foreach $downloadserver ( @downloadservers )  {
-	opendir ( DIR , $log_incoming_root."/".$downloadserver );
-	@files = readdir( DIR );
-
-	foreach ( @files )  {
-		if( /.*\.log$/ )  {
-			Vhffs::Functions::rotate_log( $log_incoming_root."/".$downloadserver."/".$_ , $log_incoming_rotations , $log_incoming_compress );
-		}
-	}
-
-	# put a file to tell webserver to restart (ugly signaling over nfs, I know I know... but IT WORKS, it is secure, and doesn't consume too much CPU !)
-	open( FILECYCLE , "> ".$log_incoming_root."/".$downloadserver."/cycleok" );
-	print FILECYCLE "";
-	close( FILECYCLE );
-}
-
-# Restart locally or wait 180 seconds to be sure all apache are restarted (welcome to the land of pigs)
-if( $log_apachelocal )  {
-	my $cmd = $log_apachectl." graceful";
-	system ( $cmd );
-} else {
-	sleep ( 180 );
-}
-
-# Deleting previous logs
-unlink $log_incoming_root."/mergedlog" if( -f $log_incoming_root."/mergedlog" );
-unlink $log_incoming_root."/rejectlog" if( -f $log_incoming_root."/rejectlog" );
-
-# Merge all logs
-my $cmd = "mergelog ".$log_incoming_root."/*/http.log.0 ".$log_incoming_root."/*/ftp.log.0 > ".$log_incoming_root."/mergedlog";
-system ( $cmd );
-
-# Parse http logs
-my $prev = "";
-my $ddir = $conf_datadir."/repository/";
-$ddir =~ s%[/]{2,}%/%g;
-
-open( MERGEDIN , "< ".$log_incoming_root."/mergedlog" );
-open( REJECTOUT, "> ".$log_incoming_root."/rejectlog" );
-
-while( my $line = <MERGEDIN> )  {
-
-	$line =~ s/\n//;
-
-	# is it a ftp or http log ?
-	my ( undef , undef , $type , undef ) = split( /\ /, $line, 4);
-
-	# modify loglines to produce an uniformised output for ftp and http
-	if( $type eq 'ftp' )  {
-
-		# remove the "/data/repository/" part of the query
-		$line =~ s%$ddir%%g;
-		$line =~ s%$%\ \"\-\"\ \"\-\"%;
-
-		# add HTTP/1.1 at the end of the query
-		my ( $part1 , $part2 ) = split( /\]/, $line, 2);
-		my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
-
-		$line = $part1.']'.$part21.'"'.$part22.' HTTP/1.1"'.$part23;
-
-	}  else  {
-
-		# remove the http:// part of the query if it exists
-		my ( $part1 , $part2 ) = split( /\]/, $line, 2);
-		my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
-
-		if( $part22 =~ /^\w+\ http:\/\/.+$/ ) {
-			my ( $part221 , undef ) = split( /\ / , $part22 , 2);
-			my ( undef, undef, undef, $part222) = split( /\// , $part22 , 4);
-
-			$line = $part1.']'.$part21.'"'.$part221.' /'.$part222.'"'.$part23;
-		}
-	}
-
-	# now fetch the download area and modify the logline to discard download area information
-	my ( $part1 , $part2 ) = split( /\]/, $line, 2);
-	my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
-
-	my ( $part221 , $area , $part223 ) = split( /\// , $part22 , 3);
-	my $log = $part1.']'.$part21.'"'.$part221.'/'.$part223.'"'.$part23;
-
-	# append log line to the concerned download area
-	if ( defined $area && defined $log )  {
-
-		# We are _NOT_ hosting this repository
-		if( ! exists $repositorys{$area} )  {
-
-			print REJECTOUT $area." ".$log."\n";
-		}
-
-		# We host this repository
-		else  {
-			# the repository changed
-			if ( $prev ne $area )  {
-				my $dir = $log_parsed_root."/".$area."/logs";
-				Vhffs::Functions::create_dir($dir) if ( ! -d $dir );
-
-				my $lff = $dir."/access.log";
-				close(FILEOUT);
-				open( FILEOUT , ">> ".$lff );
-				$prev = $area;
-			}
-
-			print FILEOUT $log."\n";
-		}
-	}
-}
-
-close(MERGEDIN);
-close(REJECTOUT);
-close(FILEOUT);
-
-
-# Create a configuration file and generate statistic for each website
-foreach ( @{$repos} )
-{
-	my $reponame = $_->get_name;
-
-	my $weblogdir = $log_parsed_root."/".$reponame;
-	my $logpath = $weblogdir."/logs/access.log";
-	my $datadir = $weblogdir."/awstats";
-	my $conffile = $datadir."/awstats.".$reponame.".conf";
-
-	next if ( ! -f $logpath );
-	Vhffs::Functions::create_dir($datadir) if ( ! -d $datadir );
-
-	# Create the config file
-	open( AWFILEIN , "< ".$awstats_sample );
-	open( AWFILEOUT , "> ".$conffile );
-
-	while( my $line = <AWFILEIN> )
-	{
-		$line =~ s/MY_DOMAINNAME/$reponame/g;
-		$line =~ s/MY_LOGPATH/$logpath/g;
-		$line =~ s/MY_DATADIR/$datadir/g;
-		
-		print AWFILEOUT $line;
-	}
-
-	close( AWFILEOUT );
-	close( AWFILEIN );
-
-	# Generate statistics
-	$cmd = $log_awstats." -config=".$reponame." -update 2>/dev/null 1>/dev/null";
-	system( $cmd );
-
-	# Rotate logs for this website
-	Vhffs::Functions::rotate_log( $logpath , $log_parsed_rotation , $log_parsed_compress );
-}
-
-Vhffs::Robots::unlock( $vhffs , "repositorystats" );

Deleted: trunk/vhffs-robots/src/generate_webstats.pl
===================================================================
--- trunk/vhffs-robots/src/generate_webstats.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/generate_webstats.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,217 +0,0 @@
-#!%PERL% -w
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-#Your logs must be in format : "%V %h %l %u %t \"%r\" %>s %b"
-#So, add in your httpd.conf following lines :
-#LogFormat "%V %h %l %u %t \"%r\" %>s %b" vhffs
-#CustomLog /var/log/apache2/vhffs.log vhffs
-
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Conf;
-use Vhffs::Functions;
-use Vhffs::Services::Web;
-use Vhffs::Robots;
-
-my $vhffs = init Vhffs::Main;
-die "ERROR: Cannot init VHFFS !!!" if( ! defined $vhffs );
-
-my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-die "ERROR: Cannot fetch the list of websites\n" if( ! defined $webs );
-
-my $webconf = Vhffs::Conf::get_web_config();
-die "ERROR: A full web configuration is needed to generate stats\n" if ( ! defined $webconf );
-
-my $log_incoming_root = $webconf->{"log_incoming_root"};
-my $log_incoming_rotations = $webconf->{"log_incoming_rotations"};
-my $log_incoming_compress = ( $webconf->{"log_incoming_compress"} eq 'yes' ) ? 1 : 0;
-my $log_parsed_root = $webconf->{"log_parsed_root"};
-my $log_parsed_rotation = $webconf->{"log_parsed_rotation"};
-my $log_parsed_compress = ( $webconf->{"log_parsed_compress"} eq 'yes' ) ? 1 : 0;
-my $log_awstats = $webconf->{"log_awstats"};
-my $awstats_sample = $webconf->{"log_awstats_sample"};
-my $log_apachelocal = ( $webconf->{"log_apachelocal"} eq 'yes' ) ? 1 : 0;
-my $log_apachectl = $webconf->{"log_apachectl"};
-
-die "ERROR: ".$log_incoming_root." is not a directory" if( ! -d $log_incoming_root );
-die "ERROR: ".$log_parsed_root." is not a directory" if( ! -d $log_parsed_root );
-die "ERROR: ".$log_awstats." does no exist" if( ! -f $log_awstats );
-die "ERROR: cannot find the awstat sample at ".$awstats_sample if( ! -f $awstats_sample );
-die "ERROR: cannot find the apache2ctl binary at ".$log_apachectl if( $log_apachelocal  &&  ! -f $log_apachectl );
-
-Vhffs::Robots::lock( $vhffs , "webstats" );
-
-my %websites;
-foreach ( @{$webs} )  {
-	$websites{$_->get_servername} = 1;
-}
-
-my @webservers;
-my $webserver;
-my @files;
-
-# -- Rotate web servers logs (all *.log files, I know that the suffix is hardcoded but I don't
-#    bother to add a configuration entry for that, it's already too complicated, and, who would
-#    like anything other than .log ? ).
-
-opendir( DIR , $log_incoming_root );
-@files = readdir( DIR );
-
-foreach( @files )  {
-	next if( /\./ );
-	if( -d $log_incoming_root."/".$_ )  {
-		push @webservers, $_;
-	}
-}
-closedir( DIR );
-
-
-foreach $webserver ( @webservers )  {
-	opendir ( DIR , $log_incoming_root."/".$webserver );
-	@files = readdir( DIR );
-
-	foreach ( @files )  {
-		if( /.*\.log$/ )  {
-			Vhffs::Functions::rotate_log( $log_incoming_root."/".$webserver."/".$_ , $log_incoming_rotations , $log_incoming_compress );
-		}
-	}
-
-	# put a file to tell webserver to restart (ugly signaling over nfs, I know I know... but IT WORKS, it is secure, and doesn't consume too much CPU !)
-	open( FILECYCLE , "> ".$log_incoming_root."/".$webserver."/cycleok" );
-	print FILECYCLE "";
-	close( FILECYCLE );
-}
-
-# Restart locally or wait 180 seconds to be sure all apache are restarted (welcome to the land of pigs)
-if( $log_apachelocal )  {
-	my $cmd = $log_apachectl." graceful";
-	system ( $cmd );
-} else {
-	sleep ( 180 );
-}
-
-# Deleting previous logs
-unlink $log_incoming_root."/mergedlog" if( -f $log_incoming_root."/mergedlog" );
-unlink $log_incoming_root."/rejectlog" if( -f $log_incoming_root."/rejectlog" );
-
-# Merge all logs
-my $cmd = "mergelog ".$log_incoming_root."/*/vhffs.log.0 > ".$log_incoming_root."/mergedlog";
-system ( $cmd );
-
-
-# Parse http logs
-my %logs;
-my $line;
-my $svname;
-my $log;
-my $prev = "";
-
-open( MERGEDIN , "< ".$log_incoming_root."/mergedlog" );
-open( REJECTOUT, "> ".$log_incoming_root."/rejectlog" );
-
-while( $line = <MERGEDIN> )  {
-	if( ( $svname , $log ) = ( $line =~ /([a-zA-Z0-9\.\-]+)\s(.+)/g) )  {
-
-		# Discard www
-		$svname =~ s/^www\.//;
-
-		# We are _NOT_ hosting this website
-		if( ! exists $websites{$svname} )  {
-
-			print REJECTOUT $svname." ".$log."\n";
-		}
-
-		# We host this website
-		else  {
-			# the website changed
-			if ( $prev ne $svname )  {
-				my $dir = $log_parsed_root."/".Vhffs::Functions::hash_webdir( $svname )."/logs";
-				Vhffs::Functions::create_dir($dir) if ( ! -d $dir );
-
-				my $lff = $dir."/access.log";
-				close(FILEOUT);
-				open( FILEOUT , ">> ".$lff );
-
-				$prev = $svname;
-			}
-
-			print FILEOUT $log."\n";
-		}
-	}
-}
-
-close(MERGEDIN);
-close(REJECTOUT);
-close(FILEOUT);
-
-
-# Create a configuration file and generate statistic for each website
-foreach ( @{$webs} )
-{
-	my $svname = $_->get_servername;
-
-	my $weblogdir = $log_parsed_root."/".Vhffs::Functions::hash_webdir( $svname );
-	my $logpath = $weblogdir."/logs/access.log";
-	my $datadir = $weblogdir."/awstats";
-	my $conffile = $datadir."/awstats.".$svname.".conf";
-
-	#next if( -f $conffile );
-
-	next if ( ! -f $logpath );
-	Vhffs::Functions::create_dir($datadir) if ( ! -d $datadir );
-
-	# Create the config file
-	open( AWFILEIN , "< ".$awstats_sample );
-	open( AWFILEOUT , "> ".$conffile );
-
-	while( $line = <AWFILEIN> )
-	{
-		$line =~ s/MY_DOMAINNAME/$svname/g;
-		$line =~ s/MY_LOGPATH/$logpath/g;
-		$line =~ s/MY_DATADIR/$datadir/g;
-		
-		print AWFILEOUT $line;
-	}
-
-	close( AWFILEOUT );
-	close( AWFILEIN );
-
-	# Generate statistics
-	$cmd = $log_awstats." -config=".$svname." -update 2>/dev/null 1>/dev/null";
-	system( $cmd );
-
-	# Rotate logs for this website
-	Vhffs::Functions::rotate_log( $logpath , $log_parsed_rotation , $log_parsed_compress );
-}
-
-Vhffs::Robots::unlock( $vhffs , "webstats" );

Copied: trunk/vhffs-robots/src/group_create.pl (from rev 798, trunk/vhffs-robots/src/create_groups.pl)
===================================================================
--- trunk/vhffs-robots/src/group_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Group;
+use Vhffs::Robots;
+use Vhffs::Robots::Group;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "usergroup" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
+
+my $group;
+
+foreach $group ( @{$groups} )
+{
+	if( Vhffs::Robots::Group::create_groupdir( $vhffs , $group ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "cannot create group %s " , $group->get_groupname ) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "create group %s " , $group->get_groupname ) , $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "usergroup" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/group_delete.pl (from rev 806, trunk/vhffs-robots/src/delete_group.pl)
===================================================================
--- trunk/vhffs-robots/src/group_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,157 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Group;
+use Vhffs::Main;
+use Vhffs::Group;
+use Vhffs::Constants;
+use Vhffs::Services::Cvs;
+use Vhffs::Services::DNS;
+use Vhffs::Services::Web;
+use Vhffs::Services::MailingList;
+use Vhffs::Services::Mail;
+use Vhffs::Services::Mysql;
+use Vhffs::Services::Pgsql;
+use Vhffs::Services::Svn;
+use Vhffs::Robots;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "usergroup" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $group;
+my $objects;
+my $object;
+my $ok;
+
+foreach $group ( @{$groups} )
+{
+	Vhffs::Robots::vhffs_log( sprintf(  "Will try to delete group %s",  $group->get_groupname), $vhffs);
+	$ok = 1;
+
+    $objects = Vhffs::Services::Cvs::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0 );
+    foreach $object ( @{$objects} )
+    {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain cvs for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+    }
+
+    $objects = Vhffs::Services::Svn::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0);
+    foreach $object ( @{$objects} )
+    {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain svn for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+    }
+
+    $objects = Vhffs::Services::DNS::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0);
+    foreach $object ( @{$objects} )
+    {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain dns for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+    }
+
+    $objects = Vhffs::Services::Mysql::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0 );
+    foreach $object ( @{$objects} )
+    {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain mysql for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+    }
+
+    $objects = Vhffs::Services::Pgsql::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0 );
+   foreach $object ( @{$objects} )
+   {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain pgsql for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+   }
+
+
+    $objects = Vhffs::Services::Web::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0 );
+   foreach $object ( @{$objects} )
+   {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain website for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+   }
+    
+	$objects = Vhffs::Services::MailingList::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0);
+   foreach $object ( @{$objects} )
+   {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain list for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		$object->commit;
+   }
+
+
+	$objects = Vhffs::Services::Mail::getall( $vhffs , undef , undef , $group );
+	$ok = 0 if( @$objects != 0 );
+   foreach $object ( @{$objects} )
+   {
+		Vhffs::Robots::vhffs_log( sprintf( "Remain mail for group %s before delete" , $group->get_groupname ), $vhffs);
+        $object->set_status( Vhffs::Constants::TO_DELETE );
+		if( $object->commit < 0 )
+		{
+			Vhffs::Robots::vhffs_log( "Error in delete group" , $vhffs);
+		}
+   }
+
+
+	if( $ok == 1 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Delete group %s" , $group->get_groupname ), $vhffs);
+		Vhffs::Robots::Group::delete( $vhffs , $group );
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot elete group %s, items remains" , $group->get_groupname ), $vhffs);
+	}
+
+}
+
+Vhffs::Robots::unlock( $vhffs , "usergroup" );
+
+exit( 0 );
+

Copied: trunk/vhffs-robots/src/group_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_groups.pl)
===================================================================
--- trunk/vhffs-robots/src/group_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,87 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Robots;
+use Vhffs::Robots::Group;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "usergroup" );
+
+$objects = Vhffs::Group::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	$user = $object->get_user;
+	$lang = Vhffs::Panel::User::get_lang( $user );
+	setlocale( LC_ALL , $lang ) if( defined $lang );
+	if( defined $user ) {
+		$message  = sprintf( gettext("Your Group request : %s ") , $object->get_groupname);
+		$message .= gettext("has been refused by the Moderators team")."\n";
+		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+		if( length( $object->get_description ) > 1 ) {
+		    $message .= gettext("Reason given : ");
+		    $message .= $object->get_description . "\n";
+		}
+		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+		$message .= gettext("Cheers,")."\n";
+		$message .= gettext("The Moderator and Admin team");
+
+        $subject = gettext("Your Group request");
+		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+	}
+		
+	$object->delete;
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "usergroup" );
+exit 0;

Copied: trunk/vhffs-robots/src/group_setquota.pl (from rev 798, trunk/vhffs-robots/src/fix_quota.pl)
===================================================================
--- trunk/vhffs-robots/src/group_setquota.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_setquota.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,90 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+require 5.004;
+use strict;
+use POSIX;
+use locale;
+use Locale::gettext;
+use Quota;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Group;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "setquota" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+my $group;
+my $blocks;
+my $user;
+my $users;
+my $inodes;
+my $dev = Quota::getqcarg($vhffs->get_config->get_datadir);
+
+foreach $group ( @{$groups} )
+{
+	$blocks = $group->get_quota * 1024;
+	$inodes = $group->get_quota * 1126400 / 100;
+
+	unless( Quota::setqlim($dev, $group->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Update quota for group %s set %s" , $group->get_groupname , $group->get_quota ) , $vhffs);
+	}
+	else
+	{
+		printf("Cannot update quota for group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
+	}
+}
+
+$users = Vhffs::User::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+
+foreach $user ( @{$users} )
+{
+    $blocks = 1024;
+	$inodes = 1126400 / 100;
+
+    unless( Quota::setqlim($dev, $user->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
+	{
+			Vhffs::Robots::vhffs_log( sprintf( "Update quota for user group %s set 1" , $user->get_username ) , $vhffs);
+	}
+	else
+	{
+		printf("Cannot update quota for group %s, reason: %s\n", $user->get_username, Quota::strerr);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "setquota" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/group_updatequotaused.pl (from rev 798, trunk/vhffs-robots/src/update_quota_used.pl)
===================================================================
--- trunk/vhffs-robots/src/group_updatequotaused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_updatequotaused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,69 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+require 5.004;
+use strict;
+use POSIX;
+use locale;
+use Locale::gettext;
+use Quota;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Group;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "getquota" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+my $group;
+my $blocks;
+my $used;
+my $dev = Quota::getqcarg($vhffs->get_config->get_datadir);
+
+foreach $group ( @$groups ) {
+	($blocks,undef,undef,undef,undef,undef,undef,undef) = Quota::query($dev, $group->get_gid, 1);
+    if(defined($blocks)) {
+        $used = ($blocks + 1024 - ($blocks % 1024)) / 1024;
+        if($group->get_quota_used() != $used) {
+            $group->set_quota_used( $used );
+            if( $group->commit > 0 ) {
+    			Vhffs::Robots::vhffs_log( sprintf( "Update quota used for group %s set %s" , $group->get_groupname , $used ) , $vhffs);
+		    }
+	    }   
+    }
+}
+
+Vhffs::Robots::unlock( $vhffs , "getquota" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/group_updatequotausedrepository.pl (from rev 798, trunk/vhffs-robots/src/update_quota_used_repository.pl)
===================================================================
--- trunk/vhffs-robots/src/group_updatequotausedrepository.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/group_updatequotausedrepository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,84 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+require 5.004;
+use strict;
+use POSIX;
+use locale;
+use Locale::gettext;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Group;
+use Vhffs::Services::Repository;
+use Quota;
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "getquotarepository" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+my $group;
+my $blocks;
+my $inodes;
+my $repos;
+my $repo;
+my $su;
+my $dev = Quota::getqcarg($vhffs->get_config->get_datadir."/".Vhffs::Constants::REPOSITORYDIR);
+
+foreach $group ( @{$groups} )
+{
+	if( defined $group )
+	{
+		$repos = Vhffs::Services::Repository::getall_per_group( $vhffs, $group);
+		if( defined $repos )
+		{
+			($blocks,undef,undef,undef,$inodes,undef,undef,undef) = Quota::query($dev, $group->get_gid, 1);
+			if ( defined $blocks )
+			{
+				$su = ($blocks+1024-($blocks%1024))/1024;
+
+				# set this space usedto all repositories of this group
+				foreach $repo ( @{$repos} )
+				{
+					$repo->set_quota_used( $su );
+					$repo->commit;
+				}
+
+				Vhffs::Robots::vhffs_log( sprintf( "Update quota used for repositories of group %s to %s MB" , $group->get_groupname , $su ) , $vhffs);
+			}
+		}
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "getquotarepository" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/mail_create.pl (from rev 798, trunk/vhffs-robots/src/create_mail.pl)
===================================================================
--- trunk/vhffs-robots/src/mail_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mail_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,68 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+#This robot create mail domain
+#It actives it
+
+# FIXME : This robot is unnecessary, we just have to activate mailbox on creation
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Services::Mail;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mail" );
+
+my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
+my $m;
+
+
+foreach $m ( @{$mails} )
+{
+	$m->add_history( "Robots will activated this mail domain" );
+	$m->set_status( Vhffs::Constants::ACTIVATED );
+	if( $m->commit > 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Create mail domain %s" , $m->get_domain ) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "cannot create mail domain %s" , $m->get_domain ) , $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "mail" );
+
+
+exit 0;

Copied: trunk/vhffs-robots/src/mail_delete.pl (from rev 806, trunk/vhffs-robots/src/delete_mail.pl)
===================================================================
--- trunk/vhffs-robots/src/mail_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mail_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,67 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+
+use Vhffs::Services::Mail;
+use Vhffs::Services::MailingList;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mail" );
+
+my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $mail;
+my $lists;
+my $list;
+foreach $mail ( @{$mails} )
+{
+    my $lists = Vhffs::Services::MailingList::getall( $vhffs , undef , undef , undef , $mail->get_domain );
+	if( @$lists != 0) {
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete mail domain %s, remains lists" , $mail->get_domain ) , $vhffs);
+		foreach $list ( @{$lists} ) {
+			$list->set_status( Vhffs::Constants::TO_DELETE );
+			$list->commit;
+		}
+	} else {
+		Vhffs::Robots::vhffs_log( sprintf( "Delete mail domain %s" , $mail->get_domain ) , $vhffs);
+		$mail->delete;
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "mail" );
+exit 0;
+

Copied: trunk/vhffs-robots/src/mail_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_mail.pl)
===================================================================
--- trunk/vhffs-robots/src/mail_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mail_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,92 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Services::Mail;
+use Vhffs::Panel::User;
+use Vhffs::Robots;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mail" );
+
+$objects = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	if( defined $object )
+	{
+		$user = $object->get_user;
+		$lang = Vhffs::Panel::User::get_lang( $user );
+		setlocale( LC_ALL , $lang ) if( defined $lang );
+		if( defined $user )
+		{
+			$message  = sprintf( gettext("Your Mail hosting request for the domain: %s ") , $object->get_domain);
+			$message .= gettext("has been refused by the Moderators team")."\n";
+			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+			if( length( $object->get_description ) > 1 )
+			{
+			    $message .= gettext("Reason given : ");
+			    $message .= $object->get_description . "\n";
+			}
+			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+			$message .= gettext("Cheers,")."\n";
+			$message .= gettext("The Moderator and Admin team");
+
+			$subject = gettext("Your Mail hosting request");
+			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+		}
+		
+		$object->delete;
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "mail" );
+exit 0;

Copied: trunk/vhffs-robots/src/mailinglist_create.pl (from rev 806, trunk/vhffs-robots/src/create_ml.pl)
===================================================================
--- trunk/vhffs-robots/src/mailinglist_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mailinglist_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,64 @@
+#!%PERL%
+
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Constants;
+use Vhffs::Services::MailingList;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "ml" );
+
+my $mls  = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
+my $ml;
+
+
+foreach $ml ( @{$mls} )
+{
+
+	$ml->set_status( Vhffs::Constants::ACTIVATED );
+	if( $ml->commit < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot create list %s", $ml->get_title ), $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Create list %s", $ml->get_title ), $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "ml" );
+
+exit 0;
+

Copied: trunk/vhffs-robots/src/mailinglist_delete.pl (from rev 806, trunk/vhffs-robots/src/delete_ml.pl)
===================================================================
--- trunk/vhffs-robots/src/mailinglist_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mailinglist_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,59 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Constants;
+use Vhffs::Robots;
+use Vhffs::Services::MailingList;
+
+
+my $vhffs  = init Vhffs::Main;
+Vhffs::Robots::lock( $vhffs , "ml" );
+my $mls  = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $ml;
+
+foreach $ml ( @{$mls} )
+{
+	if( $ml->delete < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete list %s" , $ml->get_listname ) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Delete list %s" , $ml->get_listname ) , $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "ml" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/mailinglist_refused.pl (from rev 806, trunk/vhffs-robots/src/refused_ml.pl)
===================================================================
--- trunk/vhffs-robots/src/mailinglist_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mailinglist_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,88 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Services::MailingList;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "ml" );
+
+$objects = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+    $user = $object->get_user;
+    $lang = Vhffs::Panel::User::get_lang( $user );
+    setlocale( LC_ALL , $lang ) if( defined $lang );
+    if( defined $user )
+    {
+        $message  = sprintf( gettext("Your Mailing-list request : %s ") , $object->get_listname);
+        $message .= gettext("has been refused by the Moderators team")."\n";
+        $message .= gettext("In hope to keep you in our hosting service")."\n\n";
+        if( length( $object->get_description ) > 1 )
+        {
+            $message .= gettext("Reason given : ");
+            $message .= $object->get_description . "\n";
+        }
+        $message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+        $message .= gettext("Cheers,")."\n";
+        $message .= gettext("The Moderator and Admin team");
+        $subject = gettext("Your Mailing-list request");
+        Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+    }
+		
+	$object->delete;
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "ml" );
+exit 0;

Deleted: trunk/vhffs-robots/src/modify_mysql.pl
===================================================================
--- trunk/vhffs-robots/src/modify_mysql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/modify_mysql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,61 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Robots::Mysql;
-use Vhffs::Services::Mysql;
-use Vhffs::Main;
-
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mysql" );
-
-my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_MODIFICATION , undef , undef );
-my $db;
-
-foreach $db ( @{$dbs} )
-{
-        if( Vhffs::Robots::Mysql::update_db( $vhffs , $db ) < 0 )
-		{
-			Vhffs::Robots::vhffs_log( "Error while update MySQL database" , $vhffs);
-		}
-		else
-		{
-			Vhffs::Robots::vhffs_log( sprintf( "Update MySQL database %s" , $db->get_dbname ) , $vhffs);
-		}
-}
-
-Vhffs::Robots::unlock( $vhffs , "mysql" );
-exit 0;
-

Deleted: trunk/vhffs-robots/src/modify_pgsql.pl
===================================================================
--- trunk/vhffs-robots/src/modify_pgsql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/modify_pgsql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,54 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Robots;
-use Vhffs::Services::Pgsql;
-use Vhffs::Robots::Pgsql;
-use Vhffs::Main;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "pgsql" );
-
-my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_MODIFICATION , undef , undef );
-my $db;
-
-foreach $db ( @{$dbs} )
-{
-	Vhffs::Robots::Pgsql::update_db( $vhffs , $db );
-}
-
-Vhffs::Robots::unlock( $vhffs , "pgsql" );
-
-exit 0;

Copied: trunk/vhffs-robots/src/mysql_create.pl (from rev 798, trunk/vhffs-robots/src/create_mysql.pl)
===================================================================
--- trunk/vhffs-robots/src/mysql_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mysql_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,66 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use strict;
+use POSIX;
+use locale;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Services::Mysql;
+use Vhffs::Robots::Mysql;
+use Vhffs::Constants;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mysql" );
+
+my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef );
+my $db;
+
+
+foreach $db ( @{$dbs} )
+{
+	if( Vhffs::Robots::Mysql::create_db( $vhffs , $db ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf("Cannot create MySQL database %s",$db->get_dbname) , $vhffs);
+
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf("Create MySQL database %s",$db->get_dbname) , $vhffs);
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "mysql" );
+exit 0;

Copied: trunk/vhffs-robots/src/mysql_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_mysql.pl)
===================================================================
--- trunk/vhffs-robots/src/mysql_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mysql_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Robots::Mysql;
+use Vhffs::Services::Mysql;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mysql" );
+
+my $dbs = Vhffs::Services::Mysql::getall( $vhffs  , Vhffs::Constants::TO_DELETE , undef , undef  );
+my $db;
+
+
+foreach $db ( @{$dbs} )
+{
+	if( Vhffs::Robots::Mysql::delete_db( $vhffs , $db ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete MySQL database %s" , $db->get_dbname ), $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Delete MySQL database %s" , $db->get_dbname ), $vhffs);
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "mysql" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/mysql_dump.pl (from rev 798, trunk/vhffs-robots/src/dump_mysql.pl)
===================================================================
--- trunk/vhffs-robots/src/mysql_dump.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mysql_dump.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,85 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+########################################################
+# This robot make dump for each MySQL database
+# and put it on each group directory
+#
+
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Functions;
+use Vhffs::Services::Mysql;
+use Vhffs::Robots;
+
+my $vhffs = init Vhffs::Main; 
+
+Vhffs::Robots::lock( $vhffs , "dumpmysql" );
+
+my $objs  = Vhffs::Services::Mysql::getall( $vhffs  );
+my $admin_dbuser = $vhffs->get_config->get_mysql_admin_username;
+my $admin_dbpass = $vhffs->get_config->get_mysql_admin_pass;
+my $admin_dbhost = $vhffs->get_config->get_mysql_admin_host;
+my $mysqldumppath = $vhffs->get_config->get_mysql_mysqldump_path;
+
+my $obj;
+my $group;
+my $groupname;
+
+die "Error, mysqldump is not present on this system in path \"$mysqldumppath\"\n" unless( -x $mysqldumppath );
+
+foreach $obj ( @{$objs} )
+{
+		$groupname = Vhffs::Group::get_name_by_gid( $vhffs , $obj->get_owner_gid );
+		my $dbname = $obj->get_dbname;
+		my $dir = Vhffs::Functions::hash_groupname( $groupname , $vhffs );
+		if( -d $dir )
+		{
+			my $file = $dir."/".$dbname.".mysql.dump";
+			my $cmd = "$mysqldumppath -u $admin_dbuser -h $admin_dbhost -p$admin_dbpass $dbname > $file";
+			system( $cmd );
+
+			#Change the chmod if the backup succeed
+			if( -f $file )
+			{
+				chown( $obj->get_owner_uid , $obj->get_owner_gid , $file );
+				chmod( 0660 , $file );
+			}
+			
+		}
+}
+
+Vhffs::Robots::unlock( $vhffs , "dumpmysql" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/mysql_modify.pl (from rev 798, trunk/vhffs-robots/src/modify_mysql.pl)
===================================================================
--- trunk/vhffs-robots/src/mysql_modify.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mysql_modify.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,61 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Robots::Mysql;
+use Vhffs::Services::Mysql;
+use Vhffs::Main;
+
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mysql" );
+
+my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_MODIFICATION , undef , undef );
+my $db;
+
+foreach $db ( @{$dbs} )
+{
+        if( Vhffs::Robots::Mysql::update_db( $vhffs , $db ) < 0 )
+		{
+			Vhffs::Robots::vhffs_log( "Error while update MySQL database" , $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Update MySQL database %s" , $db->get_dbname ) , $vhffs);
+		}
+}
+
+Vhffs::Robots::unlock( $vhffs , "mysql" );
+exit 0;
+

Copied: trunk/vhffs-robots/src/mysql_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_mysql.pl)
===================================================================
--- trunk/vhffs-robots/src/mysql_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/mysql_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,64 @@
+#!%PERL%
+
+use strict;
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Robots;
+use Vhffs::Services::Mysql;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "mysql" );
+
+$objects = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	if( defined $object )
+	{
+		$user = $object->get_user;
+		$lang = Vhffs::Panel::User::get_lang( $user );
+		setlocale( LC_ALL , $lang ) if( defined $lang );
+		if( defined $user )
+		{
+			$message  = sprintf( gettext("Your MySQL database request : %s ") , $object->get_dbname );
+			$message .= gettext("has been refused by the Moderators team")."\n";
+			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+			if( length( $object->get_description ) > 1 )
+			{
+			    $message .= gettext("Reason given : ");
+			    $message .= $object->get_description . "\n";
+			}
+			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+			$message .= gettext("Cheers,")."\n";
+			$message .= gettext("The Moderator and Admin team");
+
+			$subject = gettext("Your MySQL database request");
+			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+		}
+		
+		$object->delete;
+	}
+}
+
+
+
+Vhffs::Robots::unlock( $vhffs , "mysql" );
+exit 0;

Copied: trunk/vhffs-robots/src/pgsql_create.pl (from rev 804, trunk/vhffs-robots/src/create_pgsql.pl)
===================================================================
--- trunk/vhffs-robots/src/pgsql_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/pgsql_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,60 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Pgsql;
+use Vhffs::Main;
+use Vhffs::Robots;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "pgsql" );
+
+my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION );
+my $db;
+
+foreach $db ( @{$dbs} )
+{
+	if( Vhffs::Robots::Pgsql::create_db( $vhffs , $db ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf("Cannot create PostgreSQL database %s",$db->get_dbname) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf("Create PostgreSQL database %s",$db->get_dbname) , $vhffs);
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "pgsql" );
+exit( 0 );

Copied: trunk/vhffs-robots/src/pgsql_delete.pl (from rev 804, trunk/vhffs-robots/src/delete_pgsql.pl)
===================================================================
--- trunk/vhffs-robots/src/pgsql_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/pgsql_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,61 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Services::Pgsql;
+use Vhffs::Robots::Pgsql;
+use Vhffs::Main;
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "pgsql" );
+
+my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::TO_DELETE , undef , undef  );
+my $db;
+
+
+foreach $db ( @{$dbs} )
+{
+	if(  Vhffs::Robots::Pgsql::delete_db( $vhffs , $db ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete PostgreSQL database %s" , $db->get_dbname ), $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Delete PostgreSQL database %s" , $db->get_dbname ), $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "pgsql" );
+
+exit 0;
+

Copied: trunk/vhffs-robots/src/pgsql_dump.pl (from rev 802, trunk/vhffs-robots/src/dump_pgsql.pl)
===================================================================
--- trunk/vhffs-robots/src/pgsql_dump.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/pgsql_dump.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,86 @@
+#!/usr/bin/perl
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+########################################################
+# This robot make dump for each MySQL database
+# and put it on each group directory
+#
+
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Functions;
+use Vhffs::Services::Pgsql;
+use Vhffs::Robots;
+
+my $vhffs = init Vhffs::Main; 
+
+Vhffs::Robots::lock( $vhffs , "dumppgsql" );
+
+my $objs  = Vhffs::Services::Pgsql::getall( $vhffs  );
+my $admin_dbuser = $vhffs->get_config->get_pgsql_admin_username;
+my $admin_dbpass = $vhffs->get_config->get_pgsql_admin_pass;
+my $admin_dbhost = $vhffs->get_config->get_pgsql_admin_host;
+my $pgdumppath = $vhffs->get_config->get_pgsql_pgdump_path;
+
+my $obj;
+my $group;
+my $groupname;
+
+die "Error, pg_dump is not present on this system in path \"$pgdumppath\"\n" unless( -x $pgdumppath );
+
+foreach $obj ( @{$objs} )
+{
+	$groupname = Vhffs::Group::get_name_by_gid( $vhffs , $obj->get_owner_gid );
+	my $dbname = $obj->get_dbname;
+	my $dir = Vhffs::Functions::hash_groupname( $groupname , $vhffs );
+	if( -d $dir )
+	{
+		my $file = $dir."/".$dbname.".pgsql.dump";
+		my $cmd = "$pgdumppath -U $admin_dbuser -h $admin_dbhost -b -Fc -Z6 -f $file $dbname";
+		system( $cmd );
+
+		print $cmd."\n";
+
+		#Change the chmod if the backup succeed
+		if( -f $file )
+		{
+			chown( $obj->get_owner_uid , $obj->get_owner_gid , $file );
+			chmod( 0660 , $file );
+		}		
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "dumppgsql" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/pgsql_modify.pl (from rev 804, trunk/vhffs-robots/src/modify_pgsql.pl)
===================================================================
--- trunk/vhffs-robots/src/pgsql_modify.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/pgsql_modify.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,54 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Services::Pgsql;
+use Vhffs::Robots::Pgsql;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "pgsql" );
+
+my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_MODIFICATION , undef , undef );
+my $db;
+
+foreach $db ( @{$dbs} )
+{
+	Vhffs::Robots::Pgsql::update_db( $vhffs , $db );
+}
+
+Vhffs::Robots::unlock( $vhffs , "pgsql" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/pgsql_refused.pl (from rev 802, trunk/vhffs-robots/src/refused_postgres.pl)
===================================================================
--- trunk/vhffs-robots/src/pgsql_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/pgsql_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,94 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Robots;
+use Vhffs::Services::Pgsql;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "pgsql" );
+
+$objects = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+    # useless !!! (?)
+	if( defined $object )
+	{
+		$user = $object->get_user;
+		$lang = Vhffs::Panel::User::get_lang( $user );
+		setlocale( LC_ALL , $lang ) if( defined $lang );
+		if( defined $user )
+		{
+			$message  = sprintf( gettext("Your PostgreSQL database request : %s ") , $object->get_dbname );
+			$message .= gettext("has been refused by the Moderators team")."\n";
+			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+			if( length( $object->get_description ) > 1 )
+			{
+			    $message .= gettext("Reason given : ");
+			    $message .= $object->get_description . "\n";
+			}
+			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+			$message .= gettext("Cheers,")."\n";
+			$message .= gettext("The Moderator and Admin team");
+
+			$subject = gettext("Your PostgreSQL database request");
+			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+		}
+		
+		$object->delete;
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "pgsql" );
+
+exit 0;

Deleted: trunk/vhffs-robots/src/refused_cvs.pl
===================================================================
--- trunk/vhffs-robots/src/refused_cvs.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_cvs.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,87 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Services::Cvs;
-use Vhffs::Robots;
-use Vhffs::Robots::Cvs;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "cvs" );
-
-$objects = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	$user = $object->get_user;
-	$lang = Vhffs::Panel::User::get_lang( $user );
-	setlocale( LC_ALL , $lang ) if( defined $lang );
-	if( defined $user ) {
-		$message  = sprintf( gettext("Your CVS request : %s ") , $object->get_cvsroot);
-		$message .= gettext("has been refused by the Moderators team")."\n";
-		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-		if( length( $object->get_description ) > 1 ) {
-		    $message .= gettext("Reason given : ");
-		    $message .= $object->get_description . "\n";
-		}
-		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-		$message .= gettext("Cheers,")."\n";
-		$message .= gettext("The Moderator and Admin team");
-
-		$subject = gettext("Your CVS repository request");
-		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-	}
-	
-	$object->delete;
-}
-
-Vhffs::Robots::unlock( $vhffs , "cvs" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_dns.pl
===================================================================
--- trunk/vhffs-robots/src/refused_dns.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_dns.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,92 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Robots;
-use Vhffs::Group;
-use Vhffs::Services::DNS;
-use Vhffs::Panel::User;
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "dns" );
-
-$objects = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	if( defined $object )
-	{
-		$user = $object->get_user;
-		$lang = Vhffs::Panel::User::get_lang( $user );
-		setlocale( LC_ALL , $lang ) if( defined $lang );
-		if( defined $user )
-		{
-			$message  = sprintf( gettext("Your DNS hosting request for the domain : %s ") , $object->get_domain );
-			$message .= gettext("has been refused by the Moderators team")."\n";
-			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-			if( length( $object->get_description ) > 1 )
-			{
-			    $message .= gettext("Reason given : ");
-			    $message .= $object->get_description . "\n";
-			}
-			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-			$message .= gettext("Cheers,")."\n";
-			$message .= gettext("The Moderator and Admin team");
-
-			$subject = gettext("Your DNS hosting request");
-			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-		}
-		
-		$object->delete;
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "dns" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_groups.pl
===================================================================
--- trunk/vhffs-robots/src/refused_groups.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_groups.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,87 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Robots;
-use Vhffs::Robots::Group;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "usergroup" );
-
-$objects = Vhffs::Group::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	$user = $object->get_user;
-	$lang = Vhffs::Panel::User::get_lang( $user );
-	setlocale( LC_ALL , $lang ) if( defined $lang );
-	if( defined $user ) {
-		$message  = sprintf( gettext("Your Group request : %s ") , $object->get_groupname);
-		$message .= gettext("has been refused by the Moderators team")."\n";
-		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-		if( length( $object->get_description ) > 1 ) {
-		    $message .= gettext("Reason given : ");
-		    $message .= $object->get_description . "\n";
-		}
-		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-		$message .= gettext("Cheers,")."\n";
-		$message .= gettext("The Moderator and Admin team");
-
-        $subject = gettext("Your Group request");
-		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-	}
-		
-	$object->delete;
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "usergroup" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_mail.pl
===================================================================
--- trunk/vhffs-robots/src/refused_mail.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_mail.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,92 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Services::Mail;
-use Vhffs::Panel::User;
-use Vhffs::Robots;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mail" );
-
-$objects = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	if( defined $object )
-	{
-		$user = $object->get_user;
-		$lang = Vhffs::Panel::User::get_lang( $user );
-		setlocale( LC_ALL , $lang ) if( defined $lang );
-		if( defined $user )
-		{
-			$message  = sprintf( gettext("Your Mail hosting request for the domain: %s ") , $object->get_domain);
-			$message .= gettext("has been refused by the Moderators team")."\n";
-			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-			if( length( $object->get_description ) > 1 )
-			{
-			    $message .= gettext("Reason given : ");
-			    $message .= $object->get_description . "\n";
-			}
-			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-			$message .= gettext("Cheers,")."\n";
-			$message .= gettext("The Moderator and Admin team");
-
-			$subject = gettext("Your Mail hosting request");
-			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-		}
-		
-		$object->delete;
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "mail" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_ml.pl
===================================================================
--- trunk/vhffs-robots/src/refused_ml.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_ml.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,88 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Services::MailingList;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "ml" );
-
-$objects = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-    $user = $object->get_user;
-    $lang = Vhffs::Panel::User::get_lang( $user );
-    setlocale( LC_ALL , $lang ) if( defined $lang );
-    if( defined $user )
-    {
-        $message  = sprintf( gettext("Your Mailing-list request : %s ") , $object->get_listname);
-        $message .= gettext("has been refused by the Moderators team")."\n";
-        $message .= gettext("In hope to keep you in our hosting service")."\n\n";
-        if( length( $object->get_description ) > 1 )
-        {
-            $message .= gettext("Reason given : ");
-            $message .= $object->get_description . "\n";
-        }
-        $message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-        $message .= gettext("Cheers,")."\n";
-        $message .= gettext("The Moderator and Admin team");
-        $subject = gettext("Your Mailing-list request");
-        Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-    }
-		
-	$object->delete;
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "ml" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_mysql.pl
===================================================================
--- trunk/vhffs-robots/src/refused_mysql.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_mysql.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,64 +0,0 @@
-#!%PERL%
-
-use strict;
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Robots;
-use Vhffs::Services::Mysql;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "mysql" );
-
-$objects = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	if( defined $object )
-	{
-		$user = $object->get_user;
-		$lang = Vhffs::Panel::User::get_lang( $user );
-		setlocale( LC_ALL , $lang ) if( defined $lang );
-		if( defined $user )
-		{
-			$message  = sprintf( gettext("Your MySQL database request : %s ") , $object->get_dbname );
-			$message .= gettext("has been refused by the Moderators team")."\n";
-			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-			if( length( $object->get_description ) > 1 )
-			{
-			    $message .= gettext("Reason given : ");
-			    $message .= $object->get_description . "\n";
-			}
-			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-			$message .= gettext("Cheers,")."\n";
-			$message .= gettext("The Moderator and Admin team");
-
-			$subject = gettext("Your MySQL database request");
-			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-		}
-		
-		$object->delete;
-	}
-}
-
-
-
-Vhffs::Robots::unlock( $vhffs , "mysql" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_postgres.pl
===================================================================
--- trunk/vhffs-robots/src/refused_postgres.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_postgres.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,94 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Robots;
-use Vhffs::Services::Pgsql;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "pgsql" );
-
-$objects = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-    # useless !!! (?)
-	if( defined $object )
-	{
-		$user = $object->get_user;
-		$lang = Vhffs::Panel::User::get_lang( $user );
-		setlocale( LC_ALL , $lang ) if( defined $lang );
-		if( defined $user )
-		{
-			$message  = sprintf( gettext("Your PostgreSQL database request : %s ") , $object->get_dbname );
-			$message .= gettext("has been refused by the Moderators team")."\n";
-			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-			if( length( $object->get_description ) > 1 )
-			{
-			    $message .= gettext("Reason given : ");
-			    $message .= $object->get_description . "\n";
-			}
-			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-			$message .= gettext("Cheers,")."\n";
-			$message .= gettext("The Moderator and Admin team");
-
-			$subject = gettext("Your PostgreSQL database request");
-			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-		}
-		
-		$object->delete;
-	}
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "pgsql" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_repository.pl
===================================================================
--- trunk/vhffs-robots/src/refused_repository.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_repository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,92 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Services::Repository;
-use Vhffs::Robots;
-use Vhffs::Robots::Repository;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "repository" );
-
-$objects = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	if( defined $object )
-	{
-		$user = $object->get_user;
-		$lang = Vhffs::Panel::User::get_lang( $user );
-		setlocale( LC_ALL , $lang ) if( defined $lang );
-		if( defined $user )
-		{
-			$message  = sprintf( gettext("Your Download repository request : %s ") , $object->get_name);
-			$message .= gettext("has been refused by the Moderators team")."\n";
-			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-			if( length( $object->get_description ) > 1 )
-			{
-			    $message .= gettext("Reason given : ");
-			    $message .= $object->get_description . "\n";
-			}
-			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-			$message .= gettext("Cheers,")."\n";
-			$message .= gettext("The Moderator and Admin team");
-
-			$subject = gettext("Your Download repository request");
-			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-		}
-		
-		$object->delete;
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "repository" );
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_svn.pl
===================================================================
--- trunk/vhffs-robots/src/refused_svn.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_svn.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,59 +0,0 @@
-#!%PERL%
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Robots;
-use Vhffs::Services::Svn;
-use Vhffs::Panel::User;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "svn" );
-
-$objects = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	$user = $object->get_user;
-	$lang = Vhffs::Panel::User::get_lang( $user );
-	setlocale( LC_ALL , $lang ) if( defined $lang );
-	if( defined $user ) {
-		$message  = sprintf( gettext("Your Subversion repository request : %s") , $object->get_reponame);
-		$message .= gettext("has been refused by the Moderators team")."\n";
-		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-		if( length( $object->get_description ) > 1 ) {
-		    $message .= gettext("Reason given : ");
-		    $message .= $object->get_description . "\n";
-		}
-		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-		$message .= gettext("Cheers,")."\n";
-		$message .= gettext("The Moderator and Admin team");
-
-		$subject = gettext("Your Subversion repository request");
-		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-	}
-	
-	$object->delete;
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "svn" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/refused_web.pl
===================================================================
--- trunk/vhffs-robots/src/refused_web.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/refused_web.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,87 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-use POSIX qw(locale_h);
-use locale;
-use Locale::gettext;
-use strict;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::User;
-use Vhffs::Group;
-use Vhffs::Services::Web;
-use Vhffs::Panel::User;
-use Vhffs::Robots;
-
-
-my $vhffs;
-my $user;
-my $message;
-my $subject;
-my $object;
-my $lang;
-my $objects;
-
-$vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "web" );
-
-$objects = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
-bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
-textdomain("vhffs");
-
-foreach $object ( @{$objects} )
-{
-	$user = $object->get_user;
-	$lang = Vhffs::Panel::User::get_lang( $user );
-	setlocale( LC_ALL , $lang ) if( defined $lang );
-	if( defined $user ) {
-		$message  = sprintf( gettext("Your web hosting request for the servername : %s ") , $object->get_servername);
-		$message .= gettext("has been refused by the Moderators team")."\n";
-		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
-		if( length( $object->get_description ) > 1 ) {
-		    $message .= gettext("Reason given : ");
-		    $message .= $object->get_description . "\n";
-		}
-		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
-		$message .= gettext("Cheers,")."\n";
-		$message .= gettext("The Moderator and Admin team");
-
-		$subject = gettext("Your hosting request");
-		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
-	}
-		
-	$object->delete;
-}
-
-
-Vhffs::Robots::unlock( $vhffs , "web" );
-exit 0;

Copied: trunk/vhffs-robots/src/repository_create.pl (from rev 798, trunk/vhffs-robots/src/create_repository.pl)
===================================================================
--- trunk/vhffs-robots/src/repository_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/repository_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,61 @@
+#!%PERL%
+
+
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Repository;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "repository" );
+
+my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef  );
+my $repo;
+
+foreach $repo ( @{$repos} )
+{
+		if( Vhffs::Robots::Repository::create_repository( $repo ) > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "REPOSITORY: Download repository %s is created" , $repo->get_name ) , $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "REPOSITORY: Cannot create download repository %s" , $repo->get_name ) , $vhffs);
+		}
+}
+
+Vhffs::Robots::unlock( $vhffs , "repository" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/repository_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_repository.pl)
===================================================================
--- trunk/vhffs-robots/src/repository_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/repository_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,75 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Repository;
+use Vhffs::Services::Repository;
+use Vhffs::Constants;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "repository" );
+
+my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repo;
+
+foreach $repo ( @{$repos} )
+{
+    if( defined $repo )
+    {
+        if( Vhffs::Robots::Repository::delete_repository( $repo ) > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Delete files from %s", $repo->get_name ), $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from %s", $repo->get_name ), $vhffs);
+		}
+		
+		if( $repo->delete > 0 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Deleted download repository object %s", $repo->get_name ), $vhffs);
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "Cannot delete download repository object %s", $repo->get_name ), $vhffs);
+		}
+    }
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "repository" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/repository_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_repository.pl)
===================================================================
--- trunk/vhffs-robots/src/repository_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/repository_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,92 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Services::Repository;
+use Vhffs::Robots;
+use Vhffs::Robots::Repository;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "repository" );
+
+$objects = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	if( defined $object )
+	{
+		$user = $object->get_user;
+		$lang = Vhffs::Panel::User::get_lang( $user );
+		setlocale( LC_ALL , $lang ) if( defined $lang );
+		if( defined $user )
+		{
+			$message  = sprintf( gettext("Your Download repository request : %s ") , $object->get_name);
+			$message .= gettext("has been refused by the Moderators team")."\n";
+			$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+			if( length( $object->get_description ) > 1 )
+			{
+			    $message .= gettext("Reason given : ");
+			    $message .= $object->get_description . "\n";
+			}
+			$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+			$message .= gettext("Cheers,")."\n";
+			$message .= gettext("The Moderator and Admin team");
+
+			$subject = gettext("Your Download repository request");
+			Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+		}
+		
+		$object->delete;
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "repository" );
+exit 0;

Copied: trunk/vhffs-robots/src/repository_setquota.pl (from rev 798, trunk/vhffs-robots/src/fix_quota_repository.pl)
===================================================================
--- trunk/vhffs-robots/src/repository_setquota.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/repository_setquota.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,119 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+require 5.004;
+use strict;
+use POSIX;
+use locale;
+use Locale::gettext;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Group;
+use Vhffs::Services::Repository;
+use Quota;
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "setquotarepository" );
+
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+my $group;
+my $quota;
+my $blocks;
+my $inodes;
+my $repos;
+my $repo;
+my $users;
+my $user;
+my $dev = Quota::getqcarg($vhffs->get_config->get_datadir."/".Vhffs::Constants::REPOSITORYDIR);
+
+foreach $group ( @{$groups} )
+{
+	if( defined $group )
+	{
+		$quota = 0;
+		$blocks = 0;
+		$inodes = 0;
+
+		$repos = Vhffs::Services::Repository::getall_per_group( $vhffs, $group);
+		if( defined $repos )
+		{
+			foreach $repo ( @{$repos} )
+			{
+				if( defined $repo )
+				{
+					$quota += $repo->get_quota;
+					$blocks += $repo->get_quota * 1024;
+					$inodes += $repo->get_quota * 1126400 / 100;
+				}
+			}
+
+			unless( Quota::setqlim($dev, $group->get_gid, $blocks, $blocks, $inodes, $inodes, 0, 1) )
+			{
+				Vhffs::Robots::vhffs_log( sprintf( "Update quota for repositories of group %s to %s MB" , $group->get_groupname , $quota ) , $vhffs);
+			}
+			else
+			{
+				printf("Cannot update quota for repositories of group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
+			}
+		}
+		else
+		{
+			# give no space for groups without download repository
+			if( Quota::setqlim($dev, $group->get_gid, 1, 1, 1, 1, 0, 1) )
+			{
+				printf("Cannot update quota for repositories of group %s, reason: %s\n", $group->get_groupname, Quota::strerr);
+			}
+		}
+	}
+}
+
+
+# give no space for users
+$users = Vhffs::User::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+
+foreach $user ( @{$users} )
+{
+	if( defined $user )
+	{
+		# give no space for all primary groups of users
+		if( Quota::setqlim($dev, $user->get_gid, 1, 1, 1, 1, 0, 1) )
+		{
+			printf("Cannot update quota for repositories of primary group of user %s, reason %s\n", $user->get_username, Quota::strerr);
+		}
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "setquotarepository" );
+
+exit 0;

Copied: trunk/vhffs-robots/src/repository_stats.pl (from rev 798, trunk/vhffs-robots/src/generate_repositorystats.pl)
===================================================================
--- trunk/vhffs-robots/src/repository_stats.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/repository_stats.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,250 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+#Your logs must be in format : "%V %h %l %u %t \"%r\" %>s %b"
+#So, add in your httpd.conf following lines :
+#LogFormat "%V %h %l %u %t \"%r\" %>s %b" vhffs
+#CustomLog /var/log/apache2/http.log vhffs
+
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Conf;
+use Vhffs::Functions;
+use Vhffs::Services::Repository;
+use Vhffs::Robots;
+
+
+my $vhffs = init Vhffs::Main;
+die "ERROR: Cannot init VHFFS !!!" if( ! defined $vhffs );
+
+my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+die "ERROR: Cannot fetch the list of repository\n" if( ! defined $repos );
+
+my $repoconf = Vhffs::Conf::get_repository_config();
+die "ERROR: A full repository configuration is needed to generate stats\n" if ( ! defined $repoconf );
+
+my $conf_datadir = Vhffs::Conf::get_datadir;
+my $log_incoming_root = $repoconf->{"log_incoming_root"};
+my $log_incoming_rotations = $repoconf->{"log_incoming_rotations"};
+my $log_incoming_compress = ( $repoconf->{"log_incoming_compress"} eq 'yes' ) ? 1 : 0;
+my $log_parsed_root = $repoconf->{"log_parsed_root"};
+my $log_parsed_rotation = $repoconf->{"log_parsed_rotation"};
+my $log_parsed_compress = ( $repoconf->{"log_parsed_compress"} eq 'yes' ) ? 1 : 0;
+my $log_awstats = $repoconf->{"log_awstats"};
+my $awstats_sample = $repoconf->{"log_awstats_sample"};
+my $log_apachelocal = ( $repoconf->{"log_apachelocal"} eq 'yes' ) ? 1 : 0;
+my $log_apachectl = $repoconf->{"log_apachectl"};
+
+die "ERROR: ".$log_incoming_root." is not a directory" if( ! -d $log_incoming_root );
+die "ERROR: ".$log_parsed_root." is not a directory" if( ! -d $log_parsed_root );
+die "ERROR: ".$log_awstats." does no exist" if( ! -f $log_awstats );
+die "ERROR: cannot find the awstat sample at ".$awstats_sample if( ! -f $awstats_sample );
+die "ERROR: cannot find the apache2ctl binary at ".$log_apachectl if( $log_apachelocal  &&  ! -f $log_apachectl );
+
+Vhffs::Robots::lock( $vhffs , "repositorystats" );
+
+my %repositorys;
+foreach ( @{$repos} )  {
+	$repositorys{$_->get_name} = 1;
+}
+
+my @downloadservers;
+my $downloadserver;
+my @files;
+
+# -- Rotate servers logs (all *.log files, I know that the suffix is hardcoded but I don't
+#    bother to add a configuration entry for that, it's already too complicated, and, who would
+#    like anything other than .log ? ).
+
+opendir( DIR , $log_incoming_root );
+@files = readdir( DIR );
+
+foreach( @files )  {
+	next if( /\./ );
+	if( -d $log_incoming_root."/".$_ )  {
+		push @downloadservers, $_;
+	}
+}
+closedir( DIR );
+
+foreach $downloadserver ( @downloadservers )  {
+	opendir ( DIR , $log_incoming_root."/".$downloadserver );
+	@files = readdir( DIR );
+
+	foreach ( @files )  {
+		if( /.*\.log$/ )  {
+			Vhffs::Functions::rotate_log( $log_incoming_root."/".$downloadserver."/".$_ , $log_incoming_rotations , $log_incoming_compress );
+		}
+	}
+
+	# put a file to tell webserver to restart (ugly signaling over nfs, I know I know... but IT WORKS, it is secure, and doesn't consume too much CPU !)
+	open( FILECYCLE , "> ".$log_incoming_root."/".$downloadserver."/cycleok" );
+	print FILECYCLE "";
+	close( FILECYCLE );
+}
+
+# Restart locally or wait 180 seconds to be sure all apache are restarted (welcome to the land of pigs)
+if( $log_apachelocal )  {
+	my $cmd = $log_apachectl." graceful";
+	system ( $cmd );
+} else {
+	sleep ( 180 );
+}
+
+# Deleting previous logs
+unlink $log_incoming_root."/mergedlog" if( -f $log_incoming_root."/mergedlog" );
+unlink $log_incoming_root."/rejectlog" if( -f $log_incoming_root."/rejectlog" );
+
+# Merge all logs
+my $cmd = "mergelog ".$log_incoming_root."/*/http.log.0 ".$log_incoming_root."/*/ftp.log.0 > ".$log_incoming_root."/mergedlog";
+system ( $cmd );
+
+# Parse http logs
+my $prev = "";
+my $ddir = $conf_datadir."/repository/";
+$ddir =~ s%[/]{2,}%/%g;
+
+open( MERGEDIN , "< ".$log_incoming_root."/mergedlog" );
+open( REJECTOUT, "> ".$log_incoming_root."/rejectlog" );
+
+while( my $line = <MERGEDIN> )  {
+
+	$line =~ s/\n//;
+
+	# is it a ftp or http log ?
+	my ( undef , undef , $type , undef ) = split( /\ /, $line, 4);
+
+	# modify loglines to produce an uniformised output for ftp and http
+	if( $type eq 'ftp' )  {
+
+		# remove the "/data/repository/" part of the query
+		$line =~ s%$ddir%%g;
+		$line =~ s%$%\ \"\-\"\ \"\-\"%;
+
+		# add HTTP/1.1 at the end of the query
+		my ( $part1 , $part2 ) = split( /\]/, $line, 2);
+		my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
+
+		$line = $part1.']'.$part21.'"'.$part22.' HTTP/1.1"'.$part23;
+
+	}  else  {
+
+		# remove the http:// part of the query if it exists
+		my ( $part1 , $part2 ) = split( /\]/, $line, 2);
+		my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
+
+		if( $part22 =~ /^\w+\ http:\/\/.+$/ ) {
+			my ( $part221 , undef ) = split( /\ / , $part22 , 2);
+			my ( undef, undef, undef, $part222) = split( /\// , $part22 , 4);
+
+			$line = $part1.']'.$part21.'"'.$part221.' /'.$part222.'"'.$part23;
+		}
+	}
+
+	# now fetch the download area and modify the logline to discard download area information
+	my ( $part1 , $part2 ) = split( /\]/, $line, 2);
+	my ( $part21 , $part22 , $part23 ) = split( /\"/ , $part2 , 3);
+
+	my ( $part221 , $area , $part223 ) = split( /\// , $part22 , 3);
+	my $log = $part1.']'.$part21.'"'.$part221.'/'.$part223.'"'.$part23;
+
+	# append log line to the concerned download area
+	if ( defined $area && defined $log )  {
+
+		# We are _NOT_ hosting this repository
+		if( ! exists $repositorys{$area} )  {
+
+			print REJECTOUT $area." ".$log."\n";
+		}
+
+		# We host this repository
+		else  {
+			# the repository changed
+			if ( $prev ne $area )  {
+				my $dir = $log_parsed_root."/".$area."/logs";
+				Vhffs::Functions::create_dir($dir) if ( ! -d $dir );
+
+				my $lff = $dir."/access.log";
+				close(FILEOUT);
+				open( FILEOUT , ">> ".$lff );
+				$prev = $area;
+			}
+
+			print FILEOUT $log."\n";
+		}
+	}
+}
+
+close(MERGEDIN);
+close(REJECTOUT);
+close(FILEOUT);
+
+
+# Create a configuration file and generate statistic for each website
+foreach ( @{$repos} )
+{
+	my $reponame = $_->get_name;
+
+	my $weblogdir = $log_parsed_root."/".$reponame;
+	my $logpath = $weblogdir."/logs/access.log";
+	my $datadir = $weblogdir."/awstats";
+	my $conffile = $datadir."/awstats.".$reponame.".conf";
+
+	next if ( ! -f $logpath );
+	Vhffs::Functions::create_dir($datadir) if ( ! -d $datadir );
+
+	# Create the config file
+	open( AWFILEIN , "< ".$awstats_sample );
+	open( AWFILEOUT , "> ".$conffile );
+
+	while( my $line = <AWFILEIN> )
+	{
+		$line =~ s/MY_DOMAINNAME/$reponame/g;
+		$line =~ s/MY_LOGPATH/$logpath/g;
+		$line =~ s/MY_DATADIR/$datadir/g;
+		
+		print AWFILEOUT $line;
+	}
+
+	close( AWFILEOUT );
+	close( AWFILEIN );
+
+	# Generate statistics
+	$cmd = $log_awstats." -config=".$reponame." -update 2>/dev/null 1>/dev/null";
+	system( $cmd );
+
+	# Rotate logs for this website
+	Vhffs::Functions::rotate_log( $logpath , $log_parsed_rotation , $log_parsed_compress );
+}
+
+Vhffs::Robots::unlock( $vhffs , "repositorystats" );

Copied: trunk/vhffs-robots/src/svn_create.pl (from rev 798, trunk/vhffs-robots/src/create_svn.pl)
===================================================================
--- trunk/vhffs-robots/src/svn_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/svn_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,58 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Robots::Svn;
+use Vhffs::Services::Svn;
+use Vhffs::Constants;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "svn" );
+
+my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION);
+my $svn;
+foreach $svn ( @{$repos} )
+{
+	if( Vhffs::Robots::Svn::create_repo( $vhffs , $svn ) < 0 ) {
+    		Vhffs::Robots::vhffs_log( sprintf( "Cannot create SVN %s" , $svn->get_reponame ), $vhffs);
+	} else {
+		Vhffs::Robots::vhffs_log( sprintf( "Create SVN %s" , $svn->get_reponame ), $vhffs);
+		symlink('%VHFFS_BOTS_DIR%/misc/vhffs_post_commit.pl', $svn->get_dir().'/hooks/post-commit');
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "svn" );
+exit 0;

Copied: trunk/vhffs-robots/src/svn_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_svn.pl)
===================================================================
--- trunk/vhffs-robots/src/svn_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/svn_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Robots;
+use Vhffs::Robots::Svn;
+use Vhffs::Services::Svn;
+use Vhffs::Constants;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "svn" );
+
+my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::TO_DELETE);
+my $svn;
+foreach $svn ( @{$repos} )
+{
+	if( Vhffs::Robots::Svn::delete_repo( $vhffs , $svn ) < 0 )	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete files from SVN repository %s" , $svn->get_reponame ), $vhffs);
+	} else {
+		Vhffs::Robots::vhffs_log( sprintf( "Delete files from SVN repository %s" , $svn->get_reponame ), $vhffs);
+	}
+
+	if( $svn->delete < 0 ) {
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete SVN repository object %s" , $svn->get_reponame ), $vhffs);
+	} else {
+		Vhffs::Robots::vhffs_log( sprintf( "Delete SVN repository object %s" , $svn->get_reponame ), $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "svn" );
+exit 0;

Copied: trunk/vhffs-robots/src/svn_refused.pl (from rev 798, trunk/vhffs-robots/src/refused_svn.pl)
===================================================================
--- trunk/vhffs-robots/src/svn_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/svn_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,59 @@
+#!%PERL%
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Robots;
+use Vhffs::Services::Svn;
+use Vhffs::Panel::User;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "svn" );
+
+$objects = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	$user = $object->get_user;
+	$lang = Vhffs::Panel::User::get_lang( $user );
+	setlocale( LC_ALL , $lang ) if( defined $lang );
+	if( defined $user ) {
+		$message  = sprintf( gettext("Your Subversion repository request : %s") , $object->get_reponame);
+		$message .= gettext("has been refused by the Moderators team")."\n";
+		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+		if( length( $object->get_description ) > 1 ) {
+		    $message .= gettext("Reason given : ");
+		    $message .= $object->get_description . "\n";
+		}
+		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+		$message .= gettext("Cheers,")."\n";
+		$message .= gettext("The Moderator and Admin team");
+
+		$subject = gettext("Your Subversion repository request");
+		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+	}
+	
+	$object->delete;
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "svn" );
+
+exit 0;

Deleted: trunk/vhffs-robots/src/update_quota_used.pl
===================================================================
--- trunk/vhffs-robots/src/update_quota_used.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/update_quota_used.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,69 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-require 5.004;
-use strict;
-use POSIX;
-use locale;
-use Locale::gettext;
-use Quota;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Group;
-
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "getquota" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-my $group;
-my $blocks;
-my $used;
-my $dev = Quota::getqcarg($vhffs->get_config->get_datadir);
-
-foreach $group ( @$groups ) {
-	($blocks,undef,undef,undef,undef,undef,undef,undef) = Quota::query($dev, $group->get_gid, 1);
-    if(defined($blocks)) {
-        $used = ($blocks + 1024 - ($blocks % 1024)) / 1024;
-        if($group->get_quota_used() != $used) {
-            $group->set_quota_used( $used );
-            if( $group->commit > 0 ) {
-    			Vhffs::Robots::vhffs_log( sprintf( "Update quota used for group %s set %s" , $group->get_groupname , $used ) , $vhffs);
-		    }
-	    }   
-    }
-}
-
-Vhffs::Robots::unlock( $vhffs , "getquota" );
-
-exit 0;

Deleted: trunk/vhffs-robots/src/update_quota_used_repository.pl
===================================================================
--- trunk/vhffs-robots/src/update_quota_used_repository.pl	2007-08-29 23:46:25 UTC (rev 809)
+++ trunk/vhffs-robots/src/update_quota_used_repository.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -1,84 +0,0 @@
-#!%PERL%
-# Copyright (c) vhffs project and its contributors
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without 
-# modification, are permitted provided that the following conditions 
-# are met:
-#
-# 1. Redistributions of source code must retain the above copyright 
-#   notice, this list of conditions and the following disclaimer.
-#2. Redistributions in binary form must reproduce the above copyright
-#   notice, this list of conditions and the following disclaimer in 
-#   the documentation and/or other materials provided with the 
-#   distribution.
-#3. Neither the name of vhffs nor the names of its contributors 
-#   may be used to endorse or promote products derived from this 
-#   software without specific prior written permission.
-#
-#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
-#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
-#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
-#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
-#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
-#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
-#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
-#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
-#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
-# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
-# POSSIBILITY OF SUCH DAMAGE.
-
-require 5.004;
-use strict;
-use POSIX;
-use locale;
-use Locale::gettext;
-use lib '%VHFFS_LIB_DIR%';
-use Vhffs::Main;
-use Vhffs::Robots;
-use Vhffs::Group;
-use Vhffs::Services::Repository;
-use Quota;
-
-my $vhffs = init Vhffs::Main;
-
-Vhffs::Robots::lock( $vhffs , "getquotarepository" );
-
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::ACTIVATED );
-my $group;
-my $blocks;
-my $inodes;
-my $repos;
-my $repo;
-my $su;
-my $dev = Quota::getqcarg($vhffs->get_config->get_datadir."/".Vhffs::Constants::REPOSITORYDIR);
-
-foreach $group ( @{$groups} )
-{
-	if( defined $group )
-	{
-		$repos = Vhffs::Services::Repository::getall_per_group( $vhffs, $group);
-		if( defined $repos )
-		{
-			($blocks,undef,undef,undef,$inodes,undef,undef,undef) = Quota::query($dev, $group->get_gid, 1);
-			if ( defined $blocks )
-			{
-				$su = ($blocks+1024-($blocks%1024))/1024;
-
-				# set this space usedto all repositories of this group
-				foreach $repo ( @{$repos} )
-				{
-					$repo->set_quota_used( $su );
-					$repo->commit;
-				}
-
-				Vhffs::Robots::vhffs_log( sprintf( "Update quota used for repositories of group %s to %s MB" , $group->get_groupname , $su ) , $vhffs);
-			}
-		}
-	}
-}
-
-Vhffs::Robots::unlock( $vhffs , "getquotarepository" );
-
-exit 0;

Copied: trunk/vhffs-robots/src/user_create.pl (from rev 798, trunk/vhffs-robots/src/create_homes.pl)
===================================================================
--- trunk/vhffs-robots/src/user_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/user_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+
+#This robot creates home directory of each users
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::User;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "usergroup" );
+
+my $users = Vhffs::User::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef , undef );
+my $user;
+
+foreach $user ( @{$users} )
+{
+	if( Vhffs::Robots::User::create_home( $vhffs , $user ) != 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Error while creating home for %s" , $user->get_username) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Creating home/account for %s" , $user->get_username) , $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "usergroup" );
+
+exit 0;
+

Copied: trunk/vhffs-robots/src/user_delete.pl (from rev 798, trunk/vhffs-robots/src/delete_users.pl)
===================================================================
--- trunk/vhffs-robots/src/user_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/user_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,98 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Robots::User;
+use Vhffs::User;
+use Vhffs::Constants;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "usergroup" );
+
+my $lol = Vhffs::User::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $user;
+my $groups;
+my $group;
+foreach $user ( @{$lol} )
+{
+	$ok = 1;
+    if( defined $user ) 
+    {
+		$groups =  $user->get_groups;
+
+		if( defined $groups )
+		{
+			foreach $group ( @{$groups} )
+			{
+				Vhffs::Robots::vhffs_log( sprintf("Delete %s, remains group(s) : will delete %s " , $user->get_username , $group->get_groupname ) , $vhffs);
+				if( $group->get_owner_uid == $user->get_uid )
+				{
+					$ok = 0;
+					$group->set_status( Vhffs::Constants::TO_DELETE );
+					$group->commit;
+				}
+			}
+		}
+		
+		if( $ok == 1 )
+		{
+			Vhffs::Robots::vhffs_log( sprintf( "USER delete user %s" , $user->get_username ) , $vhffs);
+        	if( Vhffs::Robots::User::delete( $vhffs, $user ) < 0 )
+			{
+				Vhffs::Robots::vhffs_log( sprintf("Cannot delete user files %s" , $user->get_username ) , $vhffs);
+			}
+			else
+			{
+				Vhffs::Robots::vhffs_log( sprintf("Delete user files %s" , $user->get_username ) , $vhffs);
+			}
+
+			if( $user->delete < 0 )
+			{
+				Vhffs::Robots::vhffs_log( sprintf("Cannot delete user object %s" , $user->get_username ) , $vhffs);
+			}
+			else
+			{
+				Vhffs::Robots::vhffs_log( sprintf("Delete user object %s" , $user->get_username ) , $vhffs);
+			}
+		}
+		else
+		{
+			Vhffs::Robots::vhffs_log( sprintf("Cannot remove user %s, remains group(s)" , $user->get_username ) , $vhffs);
+		}
+    }
+}
+
+Vhffs::Robots::unlock( $vhffs , "usergroup" );
+exit 0;

Copied: trunk/vhffs-robots/src/web_create.pl (from rev 799, trunk/vhffs-robots/src/create_web.pl)
===================================================================
--- trunk/vhffs-robots/src/web_create.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/web_create.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots::Web;
+use Vhffs::Services::Web;
+use Vhffs::Robots;
+use Vhffs::Main;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "web" );
+
+my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::WAITING_FOR_CREATION , undef, undef );
+my $web;
+
+foreach $web ( @{$webs} )
+{
+	if( Vhffs::Robots::Web::create_web( $vhffs , $web ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot create web %s" , $web->get_servername ) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Create web %s" , $web->get_servername ) , $vhffs);
+	}
+}
+
+Vhffs::Robots::unlock( $vhffs , "web" );
+
+exit 0;
+

Copied: trunk/vhffs-robots/src/web_delete.pl (from rev 799, trunk/vhffs-robots/src/delete_web.pl)
===================================================================
--- trunk/vhffs-robots/src/web_delete.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/web_delete.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,62 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Robots;
+use Vhffs::Robots::Web;
+use Vhffs::Services::Web;
+use Vhffs::Main;
+use Vhffs::Constants;
+
+
+my $vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "web" );
+
+my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $web;
+
+
+foreach $web ( @{$webs} )
+{
+	if( Vhffs::Robots::Web::delete( $vhffs , $web ) < 0 )
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Cannot delete web %s" , $web->get_servername ) , $vhffs);
+	}
+	else
+	{
+		Vhffs::Robots::vhffs_log( sprintf( "Delete web %s" , $web->get_servername ) , $vhffs);
+	}
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "web" );
+exit 0;

Copied: trunk/vhffs-robots/src/web_refused.pl (from rev 799, trunk/vhffs-robots/src/refused_web.pl)
===================================================================
--- trunk/vhffs-robots/src/web_refused.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/web_refused.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,87 @@
+#!%PERL%
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+use POSIX qw(locale_h);
+use locale;
+use Locale::gettext;
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::User;
+use Vhffs::Group;
+use Vhffs::Services::Web;
+use Vhffs::Panel::User;
+use Vhffs::Robots;
+
+
+my $vhffs;
+my $user;
+my $message;
+my $subject;
+my $object;
+my $lang;
+my $objects;
+
+$vhffs = init Vhffs::Main;
+
+Vhffs::Robots::lock( $vhffs , "web" );
+
+$objects = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::VALIDATION_REFUSED );
+bindtextdomain("vhffs", $vhffs->get_config->get_intldir);
+textdomain("vhffs");
+
+foreach $object ( @{$objects} )
+{
+	$user = $object->get_user;
+	$lang = Vhffs::Panel::User::get_lang( $user );
+	setlocale( LC_ALL , $lang ) if( defined $lang );
+	if( defined $user ) {
+		$message  = sprintf( gettext("Your web hosting request for the servername : %s ") , $object->get_servername);
+		$message .= gettext("has been refused by the Moderators team")."\n";
+		$message .= gettext("In hope to keep you in our hosting service")."\n\n";
+		if( length( $object->get_description ) > 1 ) {
+		    $message .= gettext("Reason given : ");
+		    $message .= $object->get_description . "\n";
+		}
+		$message .= sprintf( gettext("If you encounters problem, please mail: %s\n") , $vhffs->get_config->get_moderator_mail ) if( defined $vhffs->get_config->get_moderator_mail );
+		$message .= gettext("Cheers,")."\n";
+		$message .= gettext("The Moderator and Admin team");
+
+		$subject = gettext("Your hosting request");
+		Vhffs::Functions::send_mail( $vhffs->get_config->get_moderator_mail , $user->get_mail , $subject , $message );
+	}
+		
+	$object->delete;
+}
+
+
+Vhffs::Robots::unlock( $vhffs , "web" );
+exit 0;

Copied: trunk/vhffs-robots/src/web_stats.pl (from rev 799, trunk/vhffs-robots/src/generate_webstats.pl)
===================================================================
--- trunk/vhffs-robots/src/web_stats.pl	                        (rev 0)
+++ trunk/vhffs-robots/src/web_stats.pl	2007-08-30 00:05:34 UTC (rev 810)
@@ -0,0 +1,217 @@
+#!%PERL% -w
+# Copyright (c) vhffs project and its contributors
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without 
+# modification, are permitted provided that the following conditions 
+# are met:
+#
+# 1. Redistributions of source code must retain the above copyright 
+#   notice, this list of conditions and the following disclaimer.
+#2. Redistributions in binary form must reproduce the above copyright
+#   notice, this list of conditions and the following disclaimer in 
+#   the documentation and/or other materials provided with the 
+#   distribution.
+#3. Neither the name of vhffs nor the names of its contributors 
+#   may be used to endorse or promote products derived from this 
+#   software without specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
+#"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
+#LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 
+#FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 
+#COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
+#INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 
+#BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
+#CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
+# POSSIBILITY OF SUCH DAMAGE.
+
+
+#Your logs must be in format : "%V %h %l %u %t \"%r\" %>s %b"
+#So, add in your httpd.conf following lines :
+#LogFormat "%V %h %l %u %t \"%r\" %>s %b" vhffs
+#CustomLog /var/log/apache2/vhffs.log vhffs
+
+use strict;
+use lib '%VHFFS_LIB_DIR%';
+use Vhffs::Main;
+use Vhffs::Conf;
+use Vhffs::Functions;
+use Vhffs::Services::Web;
+use Vhffs::Robots;
+
+my $vhffs = init Vhffs::Main;
+die "ERROR: Cannot init VHFFS !!!" if( ! defined $vhffs );
+
+my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::ACTIVATED );
+die "ERROR: Cannot fetch the list of websites\n" if( ! defined $webs );
+
+my $webconf = Vhffs::Conf::get_web_config();
+die "ERROR: A full web configuration is needed to generate stats\n" if ( ! defined $webconf );
+
+my $log_incoming_root = $webconf->{"log_incoming_root"};
+my $log_incoming_rotations = $webconf->{"log_incoming_rotations"};
+my $log_incoming_compress = ( $webconf->{"log_incoming_compress"} eq 'yes' ) ? 1 : 0;
+my $log_parsed_root = $webconf->{"log_parsed_root"};
+my $log_parsed_rotation = $webconf->{"log_parsed_rotation"};
+my $log_parsed_compress = ( $webconf->{"log_parsed_compress"} eq 'yes' ) ? 1 : 0;
+my $log_awstats = $webconf->{"log_awstats"};
+my $awstats_sample = $webconf->{"log_awstats_sample"};
+my $log_apachelocal = ( $webconf->{"log_apachelocal"} eq 'yes' ) ? 1 : 0;
+my $log_apachectl = $webconf->{"log_apachectl"};
+
+die "ERROR: ".$log_incoming_root." is not a directory" if( ! -d $log_incoming_root );
+die "ERROR: ".$log_parsed_root." is not a directory" if( ! -d $log_parsed_root );
+die "ERROR: ".$log_awstats." does no exist" if( ! -f $log_awstats );
+die "ERROR: cannot find the awstat sample at ".$awstats_sample if( ! -f $awstats_sample );
+die "ERROR: cannot find the apache2ctl binary at ".$log_apachectl if( $log_apachelocal  &&  ! -f $log_apachectl );
+
+Vhffs::Robots::lock( $vhffs , "webstats" );
+
+my %websites;
+foreach ( @{$webs} )  {
+	$websites{$_->get_servername} = 1;
+}
+
+my @webservers;
+my $webserver;
+my @files;
+
+# -- Rotate web servers logs (all *.log files, I know that the suffix is hardcoded but I don't
+#    bother to add a configuration entry for that, it's already too complicated, and, who would
+#    like anything other than .log ? ).
+
+opendir( DIR , $log_incoming_root );
+@files = readdir( DIR );
+
+foreach( @files )  {
+	next if( /\./ );
+	if( -d $log_incoming_root."/".$_ )  {
+		push @webservers, $_;
+	}
+}
+closedir( DIR );
+
+
+foreach $webserver ( @webservers )  {
+	opendir ( DIR , $log_incoming_root."/".$webserver );
+	@files = readdir( DIR );
+
+	foreach ( @files )  {
+		if( /.*\.log$/ )  {
+			Vhffs::Functions::rotate_log( $log_incoming_root."/".$webserver."/".$_ , $log_incoming_rotations , $log_incoming_compress );
+		}
+	}
+
+	# put a file to tell webserver to restart (ugly signaling over nfs, I know I know... but IT WORKS, it is secure, and doesn't consume too much CPU !)
+	open( FILECYCLE , "> ".$log_incoming_root."/".$webserver."/cycleok" );
+	print FILECYCLE "";
+	close( FILECYCLE );
+}
+
+# Restart locally or wait 180 seconds to be sure all apache are restarted (welcome to the land of pigs)
+if( $log_apachelocal )  {
+	my $cmd = $log_apachectl." graceful";
+	system ( $cmd );
+} else {
+	sleep ( 180 );
+}
+
+# Deleting previous logs
+unlink $log_incoming_root."/mergedlog" if( -f $log_incoming_root."/mergedlog" );
+unlink $log_incoming_root."/rejectlog" if( -f $log_incoming_root."/rejectlog" );
+
+# Merge all logs
+my $cmd = "mergelog ".$log_incoming_root."/*/vhffs.log.0 > ".$log_incoming_root."/mergedlog";
+system ( $cmd );
+
+
+# Parse http logs
+my %logs;
+my $line;
+my $svname;
+my $log;
+my $prev = "";
+
+open( MERGEDIN , "< ".$log_incoming_root."/mergedlog" );
+open( REJECTOUT, "> ".$log_incoming_root."/rejectlog" );
+
+while( $line = <MERGEDIN> )  {
+	if( ( $svname , $log ) = ( $line =~ /([a-zA-Z0-9\.\-]+)\s(.+)/g) )  {
+
+		# Discard www
+		$svname =~ s/^www\.//;
+
+		# We are _NOT_ hosting this website
+		if( ! exists $websites{$svname} )  {
+
+			print REJECTOUT $svname." ".$log."\n";
+		}
+
+		# We host this website
+		else  {
+			# the website changed
+			if ( $prev ne $svname )  {
+				my $dir = $log_parsed_root."/".Vhffs::Functions::hash_webdir( $svname )."/logs";
+				Vhffs::Functions::create_dir($dir) if ( ! -d $dir );
+
+				my $lff = $dir."/access.log";
+				close(FILEOUT);
+				open( FILEOUT , ">> ".$lff );
+
+				$prev = $svname;
+			}
+
+			print FILEOUT $log."\n";
+		}
+	}
+}
+
+close(MERGEDIN);
+close(REJECTOUT);
+close(FILEOUT);
+
+
+# Create a configuration file and generate statistic for each website
+foreach ( @{$webs} )
+{
+	my $svname = $_->get_servername;
+
+	my $weblogdir = $log_parsed_root."/".Vhffs::Functions::hash_webdir( $svname );
+	my $logpath = $weblogdir."/logs/access.log";
+	my $datadir = $weblogdir."/awstats";
+	my $conffile = $datadir."/awstats.".$svname.".conf";
+
+	#next if( -f $conffile );
+
+	next if ( ! -f $logpath );
+	Vhffs::Functions::create_dir($datadir) if ( ! -d $datadir );
+
+	# Create the config file
+	open( AWFILEIN , "< ".$awstats_sample );
+	open( AWFILEOUT , "> ".$conffile );
+
+	while( $line = <AWFILEIN> )
+	{
+		$line =~ s/MY_DOMAINNAME/$svname/g;
+		$line =~ s/MY_LOGPATH/$logpath/g;
+		$line =~ s/MY_DATADIR/$datadir/g;
+		
+		print AWFILEOUT $line;
+	}
+
+	close( AWFILEOUT );
+	close( AWFILEIN );
+
+	# Generate statistics
+	$cmd = $log_awstats." -config=".$svname." -update 2>/dev/null 1>/dev/null";
+	system( $cmd );
+
+	# Rotate logs for this website
+	Vhffs::Functions::rotate_log( $logpath , $log_parsed_rotation , $log_parsed_compress );
+}
+
+Vhffs::Robots::unlock( $vhffs , "webstats" );


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/