This commit is contained in:
parent
b896f638fe
commit
4ba3a3712a
3 changed files with 6 additions and 5 deletions
|
|
@ -19,8 +19,8 @@
|
|||
"functions": {
|
||||
"heartbeat": {
|
||||
"uptime": {
|
||||
"interval": 50000,
|
||||
"endpoint": "http://statuspage_app_sp_1:3001/api/push/"
|
||||
"interval": 60,
|
||||
"endpoint": "https://status.flipped.codes/api/push/"
|
||||
}
|
||||
},
|
||||
"messageGarbageCollection": {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,9 @@
|
|||
// TODO: use vanilla implementation so not an entire package is needed
|
||||
const axios = require('axios');
|
||||
|
||||
const params = (pingRaw) => (
|
||||
{
|
||||
status: 'up',
|
||||
msg: 'OK',
|
||||
ping: Math.round(pingRaw),
|
||||
}
|
||||
|
|
@ -14,7 +16,7 @@ function sendHeartbeat() {
|
|||
module.exports.run = async () => {
|
||||
setInterval(() => {
|
||||
sendHeartbeat();
|
||||
}, config.functions.heartbeat.uptime.interval);
|
||||
}, config.functions.heartbeat.uptime.interval * 1000);
|
||||
};
|
||||
|
||||
module.exports.data = {
|
||||
|
|
|
|||
|
|
@ -16,8 +16,7 @@ module.exports.run = async () => {
|
|||
// client.functions.get('HEARTBEAT_BOTLIST_discordbots').run();
|
||||
// client.functions.get('HEARTBEAT_BOTLIST_motiondevelopment').run();
|
||||
// uptime page
|
||||
// TODO: curreclty not set up
|
||||
// client.functions.get('HEARTBEAT_uptime').run();
|
||||
client.functions.get('HEARTBEAT_uptime').run();
|
||||
};
|
||||
|
||||
module.exports.data = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue