CVS: ispman/lib/ISPMan ApacheMan.pm,1.34,1.35
Joerg Delker <[email protected]>
| Newsgroups | gmane.comp.isp.ispman.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/ispman/ispman/lib/ISPMan
In directory sc8-pr-cvs1:/tmp/cvs-serv9545
Modified Files:
ApacheMan.pm
Log Message:
some code cleanup
Index: ApacheMan.pm
===================================================================
RCS file: /cvsroot/ispman/ispman/lib/ISPMan/ApacheMan.pm,v
retrieving revision 1.34
retrieving revision 1.35
diff -C2 -r1.34 -r1.35
*** ApacheMan.pm 4 Jan 2004 18:56:15 -0000 1.34
--- ApacheMan.pm 6 Jan 2004 21:23:24 -0000 1.35
***************
*** 186,202 ****
}
! my $data;
! $data ={
! "ispmanVhostName" => $r->param("ispmanVhostName"),
! "cn" => $r->param("ispmanVhostName"),
! 'uidNumber' => $domain_info->{'uidNumber'},
! 'gidNumber' => $domain_info->{'gidNumber'},
! "ispmanDomain" => $domain,
! };
! $data->{'uid'}=join '.' , ($r->param("ispmanVhostName"), $r->param("ispmanDomain"));
! $data->{'homeDirectory'}=join '/' , ($domain_info->{'homeDirectory'}, "vhosts", $r->param("ispmanVhostName"));
! for (qw(ispmanVhostServerAlias ispmanVhostExtraConf ispmanVhostIpAddress ispmanVhostDocumentRoot ispmanVhostScriptDir
! FTPQuotaMBytes FTPStatus)) {
if ($r->param($_)) {
$data->{$_}=$r->param($_);
--- 186,195 ----
}
! my $data={};
! for (qw(ispmanVhostServerAlias ispmanVhostExtraConf ispmanVhostIpAddress
! ispmanVhostDocumentRoot ispmanVhostScriptDir
! FTPQuotaMBytes FTPStatus ispmanVhostStats ispmanVhostLogdir
! ispmanVhostStatdir)) {
if ($r->param($_)) {
$data->{$_}=$r->param($_);
***************
*** 208,213 ****
$data->{'objectClass'}=$self->{'Config'}{'ispmanVhostObjectclasses'};
-
-
for (qw(ispmanVhostDocumentRootOption ispmanVhostScriptDirOption)) {
if ($r->param($_)) {
--- 201,204 ----
***************
*** 218,223 ****
}
-
-
if ($self->{'ldap'}->updateEntryWithData($dn, $data)){
--- 209,212 ----
***************
*** 275,305 ****
my $scriptdiroptions=$self->as_arrayref($r->param("ispmanVhostScriptDirOption"));;
-
my $data;
$data ={
"ispmanVhostName" => $r->param("ispmanVhostName"),
! "cn" => $r->param("ispmanVhostName"),
'uidNumber' => $domain_info->{'uidNumber'},
'gidNumber' => $domain_info->{'gidNumber'},
"ispmanDomain" => $domain,
"ispmanVhostServerAlias" => $r->param("ispmanVhostServerAlias") || "",
};
- $data->{'uid'}=join '.' , ($r->param("ispmanVhostName"), $r->param("ispmanDomain"));
-
- $data->{'objectClass'}=$self->{'Config'}{'ispmanVhostObjectclasses'};
- $data->{'homeDirectory'}=join '/' , ($domain_info->{'homeDirectory'}, "vhosts", $r->param("ispmanVhostName"));
- $data->{'userPassword'}=$self->encryptPassWithMethod($r->param("userPassword"),$self->getConf('userPassHashMethod'));
- $data->{"FTPStatus"} = $r->param("FTPStatus");
- $data->{"FTPQuotaMBytes"} = $r->param("FTPQuotaMBytes");
- $data->{"cn"} = join '.', ($r->param("ispmanVhostName"), $domain);
-
-
$data->{"ispmanVhostExtraConf"} = $r->param("ispmanVhostExtraConf") if $r->param("ispmanVhostExtraConf");
-
- $data->{"ispmanVhostDocumentRootOption"} = $documentrootoptions;
- $data->{"ispmanVhostScriptDirOption"} = $scriptdiroptions;
-
-
$data->{"ispmanVhostDocumentRoot"} = $r->param("ispmanVhostDocumentRoot") || join '/', ($r->param("ispmanVhostName"), "htdocs");
$data->{"ispmanVhostScriptDir"} = $r->param("ispmanVhostScriptDir") || join '/', ($r->param("ispmanVhostName"), "cgi-bin");
--- 264,287 ----
my $scriptdiroptions=$self->as_arrayref($r->param("ispmanVhostScriptDirOption"));;
my $data;
$data ={
+ "objectClass" => $self->{'Config'}{'ispmanVhostObjectclasses'},
"ispmanVhostName" => $r->param("ispmanVhostName"),
! "cn" => (join '.', ($r->param("ispmanVhostName"), $domain)),
'uidNumber' => $domain_info->{'uidNumber'},
'gidNumber' => $domain_info->{'gidNumber'},
"ispmanDomain" => $domain,
+ "uid" => (join '.' , ($r->param("ispmanVhostName"), $r->param("ispmanDomain"))),
+ "homeDirectory" => (join '/' , ($domain_info->{'homeDirectory'}, "vhosts", $r->param("ispmanVhostName"))),
+ "userPassword" => $self->encryptPassWithMethod($r->param("userPassword"),$self->getConf('userPassHashMethod')),
"ispmanVhostServerAlias" => $r->param("ispmanVhostServerAlias") || "",
+ "FTPStatus" => $r->param("FTPStatus"),
+ "ispmanVhostStats" => $r->param("ispmanVhostStats"),
+ "FTPQuotaMBytes" => $r->param("FTPQuotaMBytes"),
+ "ispmanVhostDocumentRootOption" => $documentrootoptions,
+ "ispmanVhostScriptDirOption" => $scriptdiroptions
};
$data->{"ispmanVhostExtraConf"} = $r->param("ispmanVhostExtraConf") if $r->param("ispmanVhostExtraConf");
$data->{"ispmanVhostDocumentRoot"} = $r->param("ispmanVhostDocumentRoot") || join '/', ($r->param("ispmanVhostName"), "htdocs");
$data->{"ispmanVhostScriptDir"} = $r->param("ispmanVhostScriptDir") || join '/', ($r->param("ispmanVhostName"), "cgi-bin");
***************
*** 308,312 ****
$data->{"fileHost"} = $r->param("fileHost") || $domain_info->{'ispmanDomainDefaultFileServer'};
$data->{"DestinationAddress"} = $r->param("fileHost") || $domain_info->{'ispmanDomainDefaultFileServer'};
-
--- 290,293 ----
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click