Hi guys! I am new to opennebula. I have two node setup: sunstone is living in a small vm, and hypervisor is placed on dedicated bare-metal server with CentOS 7. I have setup nginx as reverse proxy for sunstone one the same vm. I am getting “VNC Server disconnected (code: 1006)” error. Here is my configuration:
/etc/nginx/conf.d/opennebula.conf:
upstream sunstone {
server 127.0.0.1:9869;
}
upstream vnc_proxy {
server 127.0.0.1:29876;
}
server {
listen 80;
server_name 10.xx.xx.xx;
### Permanent redirect to HTTPS (optional)
return 301 https://$server_name:443;
}
server {
listen 443 ssl;
server_name 10.xx.xx.xx;
ssl_certificate /etc/ssl/certs/nginx-selfsigned.crt;
ssl_certificate_key /etc/ssl/nginx-selfsigned.key;
### Proxy requests to upstream
location / {
proxy_pass http://sunstone;
}
location /websockify {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header x-forwarded-proto $scheme;
proxy_set_header Host $host;
proxy_http_version 1.1;
proxy_read_timeout 86400;
proxy_pass https://vnc_proxy;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
}
/etc/oned/sunstone-server.conf:
:tmpdir: /var/tmp
:one_xmlrpc: http://localhost:2633/RPC2
:host: 127.0.0.1
:port: 9869
:sessions: memory
memcache_host: localhost
:memcache_port: 11211
:memcache_namespace: opennebula.sunstone
:env: 'prod'
:debug_level: 3
:auth: opennebula
:core_auth: cipher
:remote_version: http://downloads.opennebula.org/latest
:vnc_proxy_port: 29876
:vnc_proxy_support_wss: yes
:vnc_proxy_cert: /etc/one/certs/one-tornasol.crt
:vnc_proxy_key: /etc/one/certs/one-tornasol.key
:vnc_proxy_ipv6: false
:vnc_request_password: false
:lang: en_US
:table_order: desc
:marketplace_url: http://marketplace.opennebula.systems/
:oneflow_server: http://localhost:2474/
:routes:
- oneflow
- vcenter
- support
What am I doing wrong?