diff --git a/hbbs.subdomain.conf.sample b/hbbs.subdomain.conf.sample new file mode 100644 index 0000000..58cf638 --- /dev/null +++ b/hbbs.subdomain.conf.sample @@ -0,0 +1,63 @@ +## Version 2025/11/06 +# make sure that your hbbs container is named hbbs +# make sure that your dns has a cname set for hbbs +# /ws/relay location only works if you have hbbr container configured and named hbbr +# full guide https://rustdesk.com/docs/en/self-host/rustdesk-server-pro/faq/#set-up-https-for-web-console-manually + +server { + listen 443 ssl; + listen [::]:443 ssl; + + server_name hbbs.*; + + include /config/nginx/ssl.conf; + + client_max_body_size 0; + + location / { + # enable the next two lines for http auth + #auth_basic "Restricted"; + #auth_basic_user_file /config/nginx/.htpasswd; + + # enable for ldap auth (requires ldap-server.conf in the server block) + #include /config/nginx/ldap-location.conf; + + # enable for Authelia (requires authelia-server.conf in the server block) + #include /config/nginx/authelia-location.conf; + + # enable for Authentik (requires authentik-server.conf in the server block) + #include /config/nginx/authentik-location.conf; + + include /config/nginx/proxy.conf; + include /config/nginx/resolver.conf; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + + proxy_pass http://hbbs:21114; + + } + + location /ws/id { + proxy_pass http://hbbs:21118; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + 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; + proxy_read_timeout 120s; + } + + location /ws/relay { + proxy_pass http://hbbr:21119; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + 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; + proxy_read_timeout 120s; + } +} \ No newline at end of file