|
Server : Apache/2.2.2 (Fedora) System : Linux App1.pathumtani.go.th 2.6.20-1.2320.fc5smp #1 SMP Tue Jun 12 19:40:16 EDT 2007 i686 User : apache ( 48) PHP Version : 5.2.9 Disable Function : NONE Directory : /proc/self/root/usr/libexec/webmin/ldap-server/ |
Upload File : |
#!/usr/bin/perl
# Enable or disable the LDAP server at boot
require './ldap-server-lib.pl';
&error_setup($text{'bootup_err'});
&local_ldap_server() == 1 || &error($text{'slapd_elocal'});
$access{'start'} || &error($text{'bootup_ecannot'});
&ReadParse();
&foreign_require("init", "init-lib.pl");
$iname = $config{'init_name'} || $module_name;
if ($in{'boot'}) {
$conf = &get_config();
$pidfile = &find_value("pidfile", $conf);
&init::enable_at_boot($iname, "Start OpenLDAP server",
"$config{'slapd'} 2>&1 </dev/null",
"kill `cat $pidfile`");
}
else {
&init::disable_at_boot($iname);
}
&webmin_log("boot", undef, $in{'boot'});
&redirect("");