add healthcheck.py to routinely call a URL for uptime pinging

This commit is contained in:
jesopo 2019-12-11 15:50:15 +00:00
parent 60db9ff389
commit a5554663b4

9
modules/healthcheck.py Normal file
View file

@ -0,0 +1,9 @@
#--require-config healthcheck-url
from src import ModuleManager, utils
class Module(ModuleManager.BaseModule):
@utils.hook("cron")
@utils.kwarg("schedule", "*/10")
def ten_minutes(self, event):
utils.http.request(self.bot.config["healthcheck-url"])