Fix jwt-token
This commit is contained in:
5
client/.env
Normal file
5
client/.env
Normal file
@@ -0,0 +1,5 @@
|
||||
# Local development environment
|
||||
VITE_BASE_PATH=
|
||||
|
||||
# Debug configuration
|
||||
VITE_DEBUG_ENABLED=true
|
||||
@@ -125,7 +125,7 @@ export const SocketProvider = ({ children }) => {
|
||||
const newSocket = io(APP_CONFIG.isProduction
|
||||
? window.location.origin
|
||||
: 'http://localhost:3001', {
|
||||
path: '/socket.io/'
|
||||
path: '/ws'
|
||||
});
|
||||
|
||||
newSocket.on('connect', () => {
|
||||
|
||||
@@ -95,7 +95,7 @@ server {
|
||||
}
|
||||
|
||||
# Socket.IO with WebSocket support
|
||||
location /socket.io/ {
|
||||
location /ws {
|
||||
proxy_set_header X-Tenant-Subdomain $tenant;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
|
||||
@@ -29,6 +29,7 @@ app.set('trust proxy', 1);
|
||||
|
||||
const server = createServer(app);
|
||||
const io = new Server(server, {
|
||||
path: '/ws',
|
||||
cors: {
|
||||
origin: [
|
||||
process.env.CORS_ORIGIN || "http://localhost:3000",
|
||||
|
||||
Reference in New Issue
Block a user