Skip to content

Commit

Permalink
Stopping the server after an hour to avoid unnecessary error alerts w…
Browse files Browse the repository at this point in the history
…hile this runs on Github actions
  • Loading branch information
manojVivek committed Mar 3, 2024
1 parent 89b5151 commit e50bc4c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/apps/discord-bot-server/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ import {
removeSubscription,
} from '@socialsnitch/database/src/subscription';

setTimeout(() => {
// stop the process after an hour
process.exit(0);
}, 60 * 1000);


try {
console.log('Starting...');
const bot = new DiscordClient(process.env.DISCORD_BOT_TOKEN);
Expand Down

0 comments on commit e50bc4c

Please sign in to comment.