From: rettenbe Date: Fri, 23 May 2008 13:03:50 +0000 (+0000) Subject: * gosa-si-server-nobus X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=e20c678ddff3da2b3c60a556679b8d2818e09480;p=gosa.git * gosa-si-server-nobus * under construction git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10991 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-si/modules/ClientPackages.pm b/gosa-si/modules/ClientPackages.pm index 41cecf8c4..0656f8ba5 100644 --- a/gosa-si/modules/ClientPackages.pm +++ b/gosa-si/modules/ClientPackages.pm @@ -161,18 +161,35 @@ if( $bus_ip eq "127.0.1.1" ) { $bus_ip = "127.0.0.1" } my $bus_address = "$bus_ip:$bus_port"; $main::bus_address = $bus_address; -# create general settings for this module -my $xml = new XML::Simple(); -# register at bus -if ($main::no_bus > 0) { - $bus_activ = "off" -} -if($bus_activ eq "on") { - ®ister_at_bus(); +my $hostkey = &create_passwd; +my $res = $main::known_server_db->add_dbentry( {table=>$main::known_server_tn, + primkey=>['hostname'], + hostname=>$main::server_address, + status=>'myself', + hostkey=>$hostkey, + timestamp=>&get_time(), + } ); +if (not $res == 0) { + &main::daemon_log("0 ERROR: cannot add server to known_server_db: $res", 1); +} else { + &main::daemon_log("0 INFO: '$main::server_address' successfully added to known_server_db", 5); } + +## create general settings for this module +#my $xml = new XML::Simple(); +# +## register at bus +#if ($main::no_bus > 0) { +# $bus_activ = "off" +#} +#if($bus_activ eq "on") { +# ®ister_at_bus(); +#} + + ### functions #################################################################