<@!738151527344111666> Thanks for the pointers on ...
# general
h
@User Thanks for the pointers on nginx, unfortunately it didn't quite work out for my particular use case. I'm using a system native nginx reverse proxy in front of docker containers. I have my (reusable template) config that I set up per domain/subdomain, proxying traffic to various docker containers/ports. The docs here look like a good start: https://netmaker.readthedocs.io/en/v0.8.0/server-installation.html#nginx-reverse-proxy-setup-with-https ...but not quite there, it's nginx inside docker, not running on the host machine. When joining, I get the following error:
Copy code
2022/01/18 23:53:20 [netclient] joining <my net name> at grpc.<my domain>:443
2022/01/18 23:53:21 [netclient] error installing: rpc error: code = Unavailable desc = connection closed before server preface received
2022/01/18 23:53:21 Failed to authenticate: rpc error: code = Unauthenticated desc = Something went wrong with Auto Login: rpc error: code = Unavailable desc = connection closed before server preface received
My nginx config: grpc.domain.conf:
Copy code
server {
        root /var/www/html;
        server_name grpc.<my domain>;
        client_max_body_size 0;
        underscores_in_headers on;

        location / {
            proxy_pass http://127.0.0.1:50051;
            proxy_set_header Host $host;
            proxy_set_header X-Forwarded-Host $server_name;
            proxy_set_header X-Real-IP $remote_addr;
            proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
            proxy_set_header X-Forwarded-Ssl on;
            proxy_set_header X-Forwarded-Proto $scheme;
            proxy_read_timeout  90;
            proxy_redirect http://127.0.0.1:50051 https://$host;
            proxy_pass_request_headers on;
        }
...the rest is Certbot, redirecting 80>443, fairly standard stuff. Half of the nginx config was my standard template, the rest was adapted from the example config.