Whiteboard server. Failed to verify the connection: websocket error

  • Nextcloud Server version (e.g., 29.x.x):
    • 30.0.2
  • Operating system and version (e.g., Ubuntu 24.04):
    • Ubuntu 24.04.1
  • Web server and version (e.g, Apache 2.4.25):
    • Apache/2.4.58
  • PHP version (e.g, 8.3):
    • 8.3
  • Is this the first time you’ve seen this error? (Yes / No):
    • Yes
  • When did this problem seem to first start?
    • When triad to connect Whiteboard server with Nextcloud
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • Docker Compose
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • No

Summary of the issue you are facing:

Can’t connect Whiteboard server with Nextcloud. Whiteboard server himself seams to work

Steps to replicate it (hint: details matter!):

  1. Install Whiteboard server Docker container by Docker Compose
  2. Configure reverse proxy in Apache
  3. Getting error when triad to configure connection in Nextcloud

docker-compose.yml

version: ‘3.7’

services:
  nextcloud-whiteboard-server:
    image: ghcr.io/nextcloud-releases/whiteboard:release
    ports:
      - 3002:3002
    restart: always
    environment:
      - NEXTCLOUD_URL=https://chmura.topory.org
      - JWT_SECRET_KEY=my_secret

VHost in Apache

<IfModule mod_ssl.c>
<VirtualHost *:443>
    Protocols h2 h2c http/1.1
    H2Direct on
    ServerAdmin hunter@topory.org
    ServerName chmura.topory.org
    ServerAlias *.chmura.topory.org

    ProxyPass /whiteboard http://localhost:3002/ upgrade=websocket 

    DocumentRoot /var/www/chmura.topory.org

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined

Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /etc/letsencrypt/live/chmura.topory.org/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/chmura.topory.org/privkey.pem
</VirtualHost>
</IfModule>

In browser looks fine

image

In Nextcloud allways have an error

image

Error log from Apache

[Sun Dec 22 02:04:20.065634 2024] [proxy_http:error] [pid 41172] (20014)Internal error (specific information not available): [client 46.205.207.116:62297] AH01102: error reading status line from remote server localhost:3002
[Sun Dec 22 02:04:20.065774 2024] [proxy:error] [pid 41172] [client 46.205.207.116:62297] AH00898: Error reading from remote server returned by /whiteboard/socket.io/

Any help? Please

To make the new simpler config for Apache >= 2.4.47 work, I had to remove the trailing slash in the URL, like this:

ProxyPass /whiteboard http://localhost:3002 upgrade=websocket

Btw, the older configuration for Apache < 2.4.47 still works with newer Apache versions, so maybe cou could also try that, in case the above isn’t working: https://github.com/nextcloud/whiteboard?tab=readme-ov-file#apache–2447

3 Likes

trailing slash… Long, long day because of that trailing slash…

Thank You very very much and wish You all best!

2 Likes

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.