diff --git a/centreon-plugins/cloud/docker/mode/image.pm b/centreon-plugins/cloud/docker/mode/image.pm index 5f9e18f1c..5ad1c22fd 100644 --- a/centreon-plugins/cloud/docker/mode/image.pm +++ b/centreon-plugins/cloud/docker/mode/image.pm @@ -121,6 +121,7 @@ sub run { $self->{option_results}->{port} = $self->{option_results}->{registry_port}; $self->{option_results}->{proto} = $self->{option_results}->{registry_proto}; $self->{option_results}->{hostname} = $self->{option_results}->{registry_hostname}; + $self->{http}->set_options(%{$self->{option_results}}); $jsoncontent2 = $self->{http}->request(); diff --git a/centreon-plugins/cloud/docker/mode/info.pm b/centreon-plugins/cloud/docker/mode/info.pm index 430d031c6..40a164058 100644 --- a/centreon-plugins/cloud/docker/mode/info.pm +++ b/centreon-plugins/cloud/docker/mode/info.pm @@ -57,6 +57,7 @@ sub check_options { my ($self, %options) = @_; $self->SUPER::init(%options); + $self->{http}->set_options(%{$self->{option_results}}); } sub run { diff --git a/centreon-plugins/cloud/docker/mode/listcontainers.pm b/centreon-plugins/cloud/docker/mode/listcontainers.pm index 5a78fa46a..2505a976f 100644 --- a/centreon-plugins/cloud/docker/mode/listcontainers.pm +++ b/centreon-plugins/cloud/docker/mode/listcontainers.pm @@ -49,7 +49,7 @@ sub new { "timeout:s" => { name => 'timeout' }, }); - $self->{http}->set_options(%{$self->{option_results}}); + $self->{http} = centreon::plugins::http->new(output => $self->{output}); return $self; }