From 99bc5ba5f069b73506250142439569ef771c7a97 Mon Sep 17 00:00:00 2001
From: Adar Nimrod <nimrod@shore.co.il>
Date: Sat, 18 Dec 2021 14:01:50 +0200
Subject: [PATCH] Add some documentation.

Docstrings for the different checks.
---
 src/_dns.py          | 6 ++++++
 src/auth.py          | 2 ++
 src/autoconfig.py    | 2 ++
 src/elasticsearch.py | 2 ++
 src/gitlab.py        | 2 ++
 src/imap.py          | 2 ++
 src/kibana.py        | 2 ++
 src/kodi.py          | 2 ++
 src/mta_sts.py       | 2 ++
 src/myip.py          | 2 ++
 src/nextcloud.py     | 2 ++
 src/notify.py        | 2 ++
 src/registry.py      | 2 ++
 src/smtp.py          | 2 ++
 src/ssh.py           | 2 ++
 src/transmission.py  | 2 ++
 src/utils.py         | 2 ++
 src/vouch.py         | 2 ++
 src/www.py           | 2 ++
 19 files changed, 42 insertions(+)

diff --git a/src/_dns.py b/src/_dns.py
index c0e6d1d..dacb8e2 100644
--- a/src/_dns.py
+++ b/src/_dns.py
@@ -1,3 +1,9 @@
+"""Check DNS.
+
+Check name servers, synchronization between them, TCP connection and some
+important records.
+"""
+
 from functools import lru_cache
 import dns.resolver  # pylint: disable=import-error
 import dns.query  # pylint: disable=import-error
diff --git a/src/auth.py b/src/auth.py
index b9aff69..0f49f2a 100644
--- a/src/auth.py
+++ b/src/auth.py
@@ -1,3 +1,5 @@
+"""Check the auth.shore.co.il web service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/autoconfig.py b/src/autoconfig.py
index a3404ad..f144662 100644
--- a/src/autoconfig.py
+++ b/src/autoconfig.py
@@ -1,3 +1,5 @@
+"""Check the autoconfig.shore.co.il web page."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/elasticsearch.py b/src/elasticsearch.py
index eb30170..8f39cd9 100644
--- a/src/elasticsearch.py
+++ b/src/elasticsearch.py
@@ -1,3 +1,5 @@
+"""Check the Elasticsearch service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/gitlab.py b/src/gitlab.py
index c872a31..f55c5f4 100644
--- a/src/gitlab.py
+++ b/src/gitlab.py
@@ -1,3 +1,5 @@
+"""Check Gitlab."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/imap.py b/src/imap.py
index 57fbcb1..cce71b4 100644
--- a/src/imap.py
+++ b/src/imap.py
@@ -1,3 +1,5 @@
+"""Check IMAP."""
+
 from imaplib import IMAP4_SSL
 from utils import Check
 
diff --git a/src/kibana.py b/src/kibana.py
index d41683d..e9695d9 100644
--- a/src/kibana.py
+++ b/src/kibana.py
@@ -1,3 +1,5 @@
+"""Check Kibana."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/kodi.py b/src/kodi.py
index df903c2..0fd9c1f 100644
--- a/src/kodi.py
+++ b/src/kodi.py
@@ -1,3 +1,5 @@
+"""Check Kodi."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/mta_sts.py b/src/mta_sts.py
index 4d9d073..3054ceb 100644
--- a/src/mta_sts.py
+++ b/src/mta_sts.py
@@ -1,3 +1,5 @@
+"""Check MTA-STS web page."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/myip.py b/src/myip.py
index f2f90ed..13385fa 100644
--- a/src/myip.py
+++ b/src/myip.py
@@ -1,3 +1,5 @@
+"""Check the MyIP web service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/nextcloud.py b/src/nextcloud.py
index c5d29a8..928f0a9 100644
--- a/src/nextcloud.py
+++ b/src/nextcloud.py
@@ -1,3 +1,5 @@
+"""Check Nextcloud."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/notify.py b/src/notify.py
index ffdfcde..6a11d16 100644
--- a/src/notify.py
+++ b/src/notify.py
@@ -1,3 +1,5 @@
+"""Check the notify web service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/registry.py b/src/registry.py
index 5926620..c239083 100644
--- a/src/registry.py
+++ b/src/registry.py
@@ -1,3 +1,5 @@
+"""Check the container image registry and frontend."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/smtp.py b/src/smtp.py
index 20afdf1..a2952ce 100644
--- a/src/smtp.py
+++ b/src/smtp.py
@@ -1,3 +1,5 @@
+"""Check SMTP."""
+
 from smtplib import SMTP
 from utils import Check
 
diff --git a/src/ssh.py b/src/ssh.py
index 38e92d7..1824b2a 100644
--- a/src/ssh.py
+++ b/src/ssh.py
@@ -1,3 +1,5 @@
+"""Check SSH."""
+
 import socket
 from utils import Check
 
diff --git a/src/transmission.py b/src/transmission.py
index 3d53e3d..97eca32 100644
--- a/src/transmission.py
+++ b/src/transmission.py
@@ -1,3 +1,5 @@
+"""Check the Transmission web service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/utils.py b/src/utils.py
index c764dab..c89283e 100644
--- a/src/utils.py
+++ b/src/utils.py
@@ -1,3 +1,5 @@
+"""Utilities for common checks."""
+
 import os
 import boto3  # pylint: disable=import-error
 import requests  # pylint: disable=import-error,useless-suppression
diff --git a/src/vouch.py b/src/vouch.py
index e689a0f..c00cc48 100644
--- a/src/vouch.py
+++ b/src/vouch.py
@@ -1,3 +1,5 @@
+"""Check the Vouch service."""
+
 from utils import website_handler
 
 URLS = [
diff --git a/src/www.py b/src/www.py
index e675d73..9180bdd 100644
--- a/src/www.py
+++ b/src/www.py
@@ -1,3 +1,5 @@
+"""Check the shore.co.il and www.shore.co.il web sites."""
+
 from utils import website_handler
 
 URLS = [
-- 
GitLab