Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

461
Visualizações
Failed to start the transport 'WebSockets': null, Plesk Apache

I have a single page application, this application is developed with .net CORE + ReactJS. I managed to run the application on centos 7 + plesk panel. I made the Apache settings in the Plesk panel, but the websocket gives an error. How can I solve it?

I get the following error when the application runs.

WebSocket connection to 'wss://mydomaindomain.xyz/hubCon?id=epgy-kgVtR9HU7kxgErVAQ&access_token=eyJhbGciOiJodHRwOi8vd3d3LnczLm9yZy8yMDAxLzA0L3htbGRzaWctbW9yZSNobWFjLXNoYTI1NiIsInR5cCI6IkpXVCJ9...................

[2021-07-26T15:18:08.636Z] Error: Failed to start the transport 'WebSockets': null

Here is the Apache settings section in the Plesk panel.

Header set Access-Control-Allow-Origin "http://mydomaindomain.xyz"
Header set Access-Control-Allow-Headers "Access-Control-Allow-Headers, Origin, Accept, X-Requested-With, Content-Type, Access-Control-Request-Method, Access-Control-Request-Headers, Authorization, Content-Disposition"
Header set Access-Control-Allow-Methods "*"
Header set Access-Control-Allow-Credentials "true"

ProxyPreserveHost On
ProxyPass / http://127.0.0.1:5000/
ProxyPassReverse / http://127.0.0.1:5000/
over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

I solved the problem, put the code below in the nginx section under apache & nginx settings in the plesk panel, the problem will be solved.

location ^~ /yourSocketName {
    
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    
        proxy_set_header X-Frame-Options SAMEORIGIN;
        proxy_pass http://127.0.0.1:5000;
    }
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda