Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Picasoft
Technique
Dockerfiles
Commits
af092068
Verified
Commit
af092068
authored
Sep 03, 2021
by
Quentin Duchemin
Browse files
Watch mail server with blackbox tcp module
parent
44b7813f
Changes
2
Hide whitespace changes
Inline
Side-by-side
pica-metrologie/blackbox.yml
View file @
af092068
...
...
@@ -22,3 +22,22 @@ modules:
dns
:
query_name
:
picasoft.net
query_type
:
SOA
# Probe a Postfix server and check STARTTLS mechanism
smtp_check
:
prober
:
tcp
timeout
:
5s
tcp
:
preferred_ip_protocol
:
"
ip4"
query_response
:
# Check that HELO command works
-
expect
:
"
^220
([^
]+)
ESMTP
(.+)$"
-
send
:
"
HELO
ProberCheck"
-
expect
:
"
^250(.+)"
# Upgrade to TLS and check that HELO still works
-
send
:
"
STARTTLS"
-
expect
:
"
^220(.+)"
-
starttls
:
true
-
send
:
"
HELO
ProberCheck"
-
expect
:
"
^250(.+)"
-
send
:
"
QUIT"
pica-metrologie/vmagent-prom.yml
View file @
af092068
...
...
@@ -184,6 +184,19 @@ scrape_configs:
target_label
:
instance
-
target_label
:
__address__
replacement
:
blackbox.picasoft.net
# Srape metrics about Picasoft mail server
-
job_name
:
blackbox-mail
scheme
:
"
https"
basic_auth
:
username
:
"
%{BLACKBOX_METRICS_USER}"
password
:
"
%{BLACKBOX_METRICS_PASSWORD}"
metrics_path
:
/probe
params
:
module
:
[
smtp_check
]
target
:
[
mail.picasoft.net
:
587
]
static_configs
:
-
targets
:
-
blackbox.picasoft.net
# Scrape metrics about Blackbox itself
-
job_name
:
blackbox
scheme
:
"
https"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment