Last fixes for v0.2.0
This commit is contained in:
parent
d9ad94e579
commit
9556889d83
3 changed files with 9 additions and 9 deletions
12
index.js
12
index.js
|
|
@ -139,14 +139,14 @@ const processLogLine = async line => {
|
|||
});
|
||||
});
|
||||
|
||||
if (process?.send) process.send('ready');
|
||||
// Auto updates
|
||||
if (AUTO_UPDATE_ENABLED && AUTO_UPDATE_SCHEDULE) await require('./services/updates.js')();
|
||||
if (DISCORD_WEBHOOKS_ENABLED && DISCORD_WEBHOOKS_URL) await require('./services/summaries.js')();
|
||||
|
||||
await discordWebhooks(0, `[UFW-AbuseIPDB-Reporter](https://github.com/sefinek/UFW-AbuseIPDB-Reporter) has been successfully launched on the device \`${SERVER_ID}\`.`);
|
||||
|
||||
log(0, `Ready! Now monitoring: ${UFW_LOG_FILE}`);
|
||||
log(0, '=====================================================================');
|
||||
|
||||
await discordWebhooks(0, `[UFW-AbuseIPDB-Reporter](https://github.com/sefinek/UFW-AbuseIPDB-Reporter) has been successfully launched on the device \`${SERVER_ID}\`.`);
|
||||
|
||||
// Auto updates
|
||||
if (AUTO_UPDATE_ENABLED && AUTO_UPDATE_SCHEDULE) await require('./services/updates.js')();
|
||||
if (DISCORD_WEBHOOKS_ENABLED && DISCORD_WEBHOOKS_URL) await require('./services/summaries.js')();
|
||||
process.send && process.send('ready');
|
||||
})();
|
||||
|
|
@ -68,6 +68,6 @@ const sendWebhook = async () => {
|
|||
};
|
||||
|
||||
module.exports = async () => {
|
||||
await sendWebhook();
|
||||
// await sendWebhook();
|
||||
new CronJob('0 0 * * *', sendWebhook, null, true, 'UTC');
|
||||
};
|
||||
};
|
||||
|
|
@ -10,7 +10,7 @@ const git = simpleGit();
|
|||
|
||||
const pull = async () => {
|
||||
await discordWebhooks(4, 'Updating the local repository in progress `(git pull)`...');
|
||||
log(0, '$ git pull');
|
||||
log(0, 'Running git pull...');
|
||||
|
||||
try {
|
||||
const { summary } = await git.pull();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue