-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
851bb63
commit c22c5ed
Showing
1 changed file
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# mesoneer-tls-certificate-watchbot | ||
|
||
A poorman's TLS certificate monitoring system. It leverages GitHub Actions to run a workflow daily to probe the TLS certificate of the sites and notify if the expiration date is near. | ||
|
||
## How it works | ||
|
||
The gist of this is the GitHub Action Workflow `tls-certificate-check.yaml` in `.github/workflows`. | ||
|
||
It basically, for each defined site, probe its TLS certificate, then -- depends on the expiration date, send a Slack notification if needed. | ||
|
||
## Sites | ||
|
||
All monitored sites are defined in `sites.json`. The structure is deadly simple: | ||
|
||
```json | ||
{ | ||
"sites": [ | ||
{ "domain": "example.org", "port" : 443 }, | ||
{ "domain": "another.example.org", "port": 8443 } | ||
] | ||
} | ||
``` | ||
|
||
## Monitoring Logs | ||
|
||
The workflow will add a Git commit every time it runs (to ensure that the repo is always active). The file `executions.jsonl` is also appended with a JSON line containing the result of the check. | ||
|
||
NOTE: JSONL - https://jsonlines.org/ - is used as it suits the purpose. |