Skip to content

Commit

Permalink
enh(legacy): cbd reload after remote-server import (#232)
Browse files Browse the repository at this point in the history
  • Loading branch information
garnier-quentin authored May 10, 2022
1 parent 280c347 commit bad7dda
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions gorgone/gorgone/modules/centreon/legacycmd/class.pm
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,8 @@ sub execute_cmd {
data => {
logging => $options{logging},
content => {
parent_id => $options{param}
parent_id => $options{param},
cbd_reload => 'sudo ' . $self->{pollers}->{ $options{target} }->{broker_reload_command}
}
}
);
Expand Down Expand Up @@ -582,10 +583,23 @@ sub action_addimporttaskwithparent {
{
command => $cmd
}
],
parameters => { no_fork => 1 }
}
);
$self->send_internal_action(
action => 'COMMAND',
token => $options{token},
data => {
logging => $options{data}->{logging},
content => [
{
command => $options{data}->{content}->{cbd_reload}
}
]
}
);

$self->send_log(
code => GORGONE_ACTION_FINISH_OK,
token => $options{token},
Expand Down

0 comments on commit bad7dda

Please sign in to comment.