Skip to content

Commit d7d11d6

Browse files
asencialbertvaka
authored andcommitted
Add additional parameters to http_check (DataDog#599)
Add the check_hostname and ssl_server_name parameters to the http_check integration
1 parent 5ab2c3b commit d7d11d6

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

manifests/integrations/http_check.pp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,8 @@
185185
$check_certificate_expiration = true,
186186
$days_warning = undef,
187187
$days_critical = undef,
188+
Optional[Boolean] $check_hostname = undef,
189+
Optional[String] $ssl_server_name = undef,
188190
$headers = [],
189191
$allow_redirects = true,
190192
$tags = [],
@@ -217,6 +219,8 @@
217219
'check_certificate_expiration' => $check_certificate_expiration,
218220
'days_warning' => $days_warning,
219221
'days_critical' => $days_critical,
222+
'check_hostname' => $check_hostname,
223+
'ssl_server_name' => $ssl_server_name,
220224
'headers' => $headers,
221225
'allow_redirects' => $allow_redirects,
222226
'tags' => $tags,

templates/agent-conf.d/http_check.yaml.erb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,12 @@ instances:
7171
<% if instance['days_critical'] -%>
7272
days_critical: <%= instance['days_critical'] %>
7373
<% end -%>
74+
<% if instance['check_hostname'] -%>
75+
check_hostname: <%= instance['check_hostname'] %>
76+
<% end -%>
77+
<% if instance['ssl_server_name'] -%>
78+
ssl_server_name: <%= instance['ssl_server_name'] %>
79+
<% end -%>
7480
<% end -%>
7581
<% end -%>
7682
<% if instance['headers'] and ! instance['headers'].empty? -%>

0 commit comments

Comments
 (0)