segfault/tools/monitor_ssh
aog 6d06457c6c move cg and monitor to tools folder
change path in files to new location

Signed-off-by: aog <theaog@users.noreply.github.com>
2023-02-24 18:28:15 +02:00
..
.gitignore move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00
go.mod move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00
go.sum move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00
main.go move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00
Makefile move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00
readme.md move cg and monitor to tools folder 2023-02-24 18:28:15 +02:00

Monitor Functional SSH (mfs)

Attempts to start a SSH session (concurrently) to each of our segfault.net instances and reports on telegram any failures to connect or login.

Admins must provide TG_KEY and TG_CHATID env variables to start the tool.

$ export TG_KEY="key"
$ export TG_CHATID="12345678"

The servers list must be supplied via CLI flags, e.g.:

$ ./mfs \
    -s de.segfault.net:secret \
    -s us.segfault.net:secret \
    -s it.segfault.net:secret

By default it checks all servers every 1 minute, you can tweak the timer e.g. -timer 5m