I got it working with letsencrypt with the following: (subdomain)
# make sure that your dns has a cname set for code-server
server {
listen 443 ssl;
listen [::]:443 ssl;
server_name rider.*;
include /config/nginx/ssl.conf;
client_max_body_size 0;
# enable for ldap auth, fill in ldap details in ldap.conf
#include /config/nginx/ldap.conf;
location / {
# enable the next two lines for http auth
#auth_basic "Restricted";
#auth_basic_user_file /config/nginx/.htpasswd;
# enable the next two lines for ldap auth
#auth_request /auth;
#error_page 401 =200 /login;
include /config/nginx/proxy.conf;
resolver 127.0.0.11 valid=30s;
set $upstream_rider binhex-rider;
proxy_pass http://$upstream_rider:6080/vnc.html?resize=remote&autoconnect=1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection upgrade;
}
}
set $upstream_rider binhex-rider; = binhex-rider is the name of the Docker cointainer
after that I had to delete cache and hard reload in Chrome and it worked.
Thanks binhex for this docker