JOKITON / ft_transcendence

Final Project of Common Core ( 42 School )
1 stars 2 forks source link

Default configuration Vite & Reverse Proxy handling WebSockets #61

Closed JOKITON closed 3 weeks ago

JOKITON commented 3 weeks ago

- There has been an issue with the setup of Nginx & Vite due to the expected configuration that Vite needed to run websockets in its default settings.

More information about this issue: https://vite.dev/config/server-options.html

JOKITON commented 3 weeks ago

I have found a link to a webpage where is explained how to configure Nginx correctly & what headers & configuration should be use to avoid these errors

Ref: https://aronschueler.de/blog/2024/07/29/enabling-hot-module-replacement-hmr-in-vite-with-nginx-reverse-proxy/

JOKITON commented 3 weeks ago

Here we have these connections correctly stablished: screenshot-correct2 screenshot-correct1

JOKITON commented 3 weeks ago

When the configuration inside Nginx was not set to manage Web Sockets directly with Vite, it outputed these errors: screenshot-fail