Add nginx reverse proxy configuration for server

This commit is contained in:
Douglas Barone 2024-01-29 13:48:04 -04:00
parent b172e10ccd
commit f66246a339

View File

@ -8,6 +8,10 @@ export class EventsController {
private static clients: { id: string; res: Response }[] = [] private static clients: { id: string; res: Response }[] = []
static async eventsHandler(req: Request, res: Response) { static async eventsHandler(req: Request, res: Response) {
/*
If the server is behind a nginx reverse proxy, use the following configuration:
proxy_read_timeout 24h;
*/
const headers = { const headers = {
'Content-Type': 'text/event-stream', 'Content-Type': 'text/event-stream',
Connection: 'keep-alive', Connection: 'keep-alive',