summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f7c15c4)
raw | patch | inline | side by side (parent: f7c15c4)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Mar 2008 15:32:51 +0000 (15:32 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Mar 2008 15:32:51 +0000 (15:32 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9362 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-si/server/events/gosaTriggered.pm | patch | blob | history | |
gosa-si/server/events/siTriggered.pm | patch | blob | history |
index 15d7f98e84f77447caa2f4fb0c9a4bf3b6f35565..81137df2dcc5fec9c7b042f205e1d016e8c34020 100644 (file)
change_fai_state('reinstall', \@{$msg_hash->{target}});
- my @out_msg_l = ($msg);
+ my %data = ( 'macAddress' => \@{$msg_hash->{target}} );
+ my $wake_msg = &build_msg("trigger_wake", "GOSA", "KNOWN_SERVER", \%data);
+ my @out_msg_l = ($wake_msg, $msg);
return @out_msg_l;
}
change_fai_state('update', \@{$msg_hash->{target}});
- my @out_msg_l = ($msg);
+ my %data = ( 'macAddress' => \@{$msg_hash->{target}} );
+ my $wake_msg = &build_msg("trigger_wake", "GOSA", "KNOWN_SERVER", \%data);
+ my @out_msg_l = ($wake_msg, $msg);
return @out_msg_l;
}
change_fai_state('update', \@{$msg_hash->{target}});
- my @out_msg_l = ($msg);
+ my %data = ( 'macAddress' => \@{$msg_hash->{target}} );
+ my $wake_msg = &build_msg("trigger_wake", "GOSA", "KNOWN_SERVER", \%data);
+ my @out_msg_l = ($wake_msg, $msg);
return @out_msg_l;
}
sub trigger_action_wake {
my ($msg, $msg_hash) = @_;
- my %data = ( 'macAddress' => \@{$msg_hash->{'macAddress'}} ,
- 'jobdb_id' => \@{$msg_hash->{'jobdb_id'}},
- );
+ my %data = ( 'macAddress' => \@{$msg_hash->{target}} );
my $out_msg = &build_msg("trigger_wake", "GOSA", "KNOWN_SERVER", \%data);
my @out_msg_l = ($out_msg);
return @out_msg_l;
}
+
sub change_fai_state {
my ($st, $targets) = @_;
index 578a968457a53537d79fd72c7b36e08e95c3908e..798dcb1dec575cd29f6c5817f91a3a41d1bba158 100644 (file)
use warnings;
use GOSA::GosaSupportDaemon;
use Socket;
+use Net::hostent;
BEGIN {}
foreach (@{$msg_hash->{macAddress}}){
&main::daemon_log("INFO: trigger wake for $_", 5);
- my $host = shift;
- my $ipaddr = shift || '255.255.255.255';
+ my $host = $_;
+ my $ipaddr = '255.255.255.255';
my $port = getservbyname('discard', 'udp');
my ($raddr, $them, $proto);