mirror of
https://github.com/benjamin-wilson/public-pool.git
synced 2026-09-29 17:15:03 -07:00
Limit background services by process role
This commit is contained in:
@@ -14,6 +14,10 @@ export class NotificationService implements OnModuleInit {
|
||||
) { }
|
||||
|
||||
async onModuleInit(): Promise<void> {
|
||||
if (process.env.MASTER !== 'true') {
|
||||
return;
|
||||
}
|
||||
|
||||
await this.discordService.notifyRestarted();
|
||||
}
|
||||
|
||||
@@ -21,4 +25,4 @@ export class NotificationService implements OnModuleInit {
|
||||
await this.discordService.notifySubscribersBlockFound(height, block, message);
|
||||
await this.telegramService.notifySubscribersBlockFound(address, height, block, message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user