Open lamousis opened 2 months ago
Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.
Webtop works fine behind a reverse proxy, you need to make sure you're handling websockets correctly. We provide a proxy conf with our swag container you can use for reference: https://github.com/linuxserver/reverse-proxy-confs/blob/master/webtop.subdomain.conf.sample
I got it working. Apparently it doesn't work with a subfolder (example.duckdns.org/webtop) but with the reverse proxy root itself (example.duckdns.org). Is the a way to work with subfolder? Every time in the location directive if I use location /webtop
I get the ui.rfb.lastActiveAt error.
Also in the nginx error log I get this
2024/05/06 20:16:33 [error] 2889#0: *523 open() "/usr/local/nginx/html/websockify" failed (2: No such file or directory), client: x.x.x.x, server: example.duckdns.org, request: "GET /websockify HTTP/1.1", host: "example.duckdns.org:8443"
Should work fine with subfolders, we provide a config for that too. Your error looks like it's having issues with web sockets.
This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.
example i used
---
services:
webtop:
image: lscr.io/linuxserver/webtop:ubuntu-kde
container_name: webtop
security_opt:
- seccomp:unconfined #optional
environment:
- TZ=Asia/Shanghai
- SUBFOLDER=/abcd/ #optional
- TITLE=VNC #optional
- CUSTOM_PORT=8888
volumes:
- ./data:/config
- /var/run/docker.sock:/var/run/docker.sock #optional
ports:
- 13000:8888
- 13001:3001
shm_size: "1gb" #optional
restart: unless-stopped
nginx config file
# cat conf.d/abcd.conf
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
server {
listen 1080;
server_name localhost;
location ^~ /abcd {
#include /config/nginx/proxy.conf;
#include /config/nginx/resolver.conf;
set $upstream_app 10.10.10.10;
set $upstream_port 13000;
set $upstream_proto http;
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_buffering off;
}
}
and then visit http://10.10.10.10:1080/abcd/
Is there an existing issue for this?
Current Behavior
I have installed webtop container (arm64 with alpine-mate tag) and it works fine on lan. Nut if I use it under my nginx reverse proxy I get this error KASMVNC encountered an error
TypeError: undefined is not an object (evaluating UI.rfb.lastActiveAt)
In the same nginx reverse proxy I also have filebrowser and jdowloader containers along with webtop and they are working fine. They are all in the same machine. The only problem comes with webtop, no matter what version I install This is my nginx.conf`map $http_upgrade $connection_upgrade { default upgrade; '' close; }
server { listen 8443 ssl;
server_name localhost;
location = /webtop {return 301 $scheme://$http_host/webtop/;} location ^~ /webtop/ { proxy_pass http://docker-webtop/; location /webtop/websockify { proxy_pass http://docker-webtop/websockify; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; proxy_read_timeout 86400; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; } }
}`
Expected Behavior
It should load the webtop without any problem just like it does on lan
Steps To Reproduce
Environment
CPU architecture
arm64
Docker creation
Container logs